Commit Graph

41 Commits

Author SHA1 Message Date
Andrius Štikonas f3dd3157a6 Initial port to KDE Frameworks 5.
The port is mostly complete:
    * A few unported items are marked with FIXME: port KF5.
    * KCFG configuration for QGroupBox is not working yet.
2014-05-18 21:41:48 +01:00
Andrius Štikonas ed431cfcd5 Partially port away from KLocale.
KLocale was replaced with KLocalizedString and QLocale.
Only changes that do not break compilation with KDELibs4 are made.
2014-05-13 23:53:37 +01:00
Andrius Štikonas 2b537490ad Port away from KDebug. 2014-05-13 14:47:35 +01:00
Andrius Štikonas 59e5a656c5 Fix detection of partitions' paths.
Previously, partition number was added to device path.
However, there are devices with more complicated numbering scheme,
e.g. memory cards may have /dev/mmcblk0p1.
It seems that the easiest way to handle this is to use partition
path instead of device path + partition number .
BUG:256964

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1337488
2013-02-05 00:09:43 +00:00
Andrius Štikonas c2900760a1 Add initial support for LVM2 Physical Volumes.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1327775
2012-12-08 15:24:07 +00:00
Volker Lanz aacd3412f5 add missing include
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1324101
2012-11-05 10:34:53 +00:00
Andrius Štikonas 98034975a7 Correctly format byte size units.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1280226
2012-02-15 17:21:40 +00:00
Volker Lanz cce6cdbacf Update a partition's system type when creating a new file system on it.
BUG:263346

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1249913
2011-08-28 15:29:26 +00:00
Volker Lanz 5156f466b8 Merge CheckOperations with NewOperations so when a new partition is deleted
before applying we don't get a dangling pointer in the CheckOperation.

BUG:275657

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1249904
2011-08-28 13:59:41 +00:00
Volker Lanz c281271807 use Device::logicalSectorSize() instead of Partition::sectorSize() where ever
possible

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135513
2010-06-07 13:36:04 +00:00
Volker Lanz 2b50c60469 rename Device::sectorSize() to Device::logicalSectorSize()
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135506
2010-06-07 13:10:55 +00:00
Volker Lanz 88494c8607 copy the old partition table pointer from the current op to the pushed op if
we're merging two ops to create partition tables on the same device

add doxygen comments for new merge method

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129889
2010-05-24 04:00:54 +00:00
Volker Lanz ed05e673e0 rename method and make description property non const; it might change, after
all, during the lifetime of the object if some other operation is merged with
this operation (generally speaking, not necessarily true for copyops)

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129885
2010-05-24 03:28:16 +00:00
Volker Lanz 0c15c050da generate the copy operation's description once in the ctor, don't dynamically
create it each time description() is called; this avoids lots of little bugs
when the source partition is, for example, resized after the copy is made or
its file system changes...

this is probably how this generally should be done for all operations.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129879
2010-05-24 02:36:29 +00:00
Volker Lanz 15e23d806e backup op does not target a device
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129869
2010-05-24 01:11:57 +00:00
Volker Lanz 5327ca792a compare partition's device path with device's, not partition table pointers
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129867
2010-05-24 01:05:01 +00:00
Volker Lanz ea4031b645 add methods to each operation to return if the op targets a given device or
partition

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129811
2010-05-23 20:13:46 +00:00
Volker Lanz d6417cbbab revert r1128581 and implement this as an additional check in
CopyOperation::canPaste() instead.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128813
2010-05-20 11:02:00 +00:00
Volker Lanz d058abce6e doxygen updates
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128312
2010-05-18 22:27:30 +00:00
Volker Lanz 4427937088 rename all progressChanged signals to progress for consistency
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098220
2010-03-03 09:18:59 +00:00
Volker Lanz 7f33130265 Add a ctor to CreatePartitionTableOperation that takes a PartitionTable
pointer, not a PartitionTable::Type. This is required for the import.

Add a basic import partition table feature to the GUI and make it work.

Add calls to PartitionManagerWidget::updatePartitions(),
MainWindow::enableActions() and the selectedPartitionChanged handler to the
operationsChanged handler to make sure the info pane and actions are always
updated when the operation stack changes (e.g. on undo). TODO: remove all
updatePartition() and similar calls from methods in PartitionManagerWidget.

Make the device properties action disabled per default and enable it only if a
device is selected. It's actually possible for no device to be selected if the
backend doesn't find any devices at all.

Fix status tips and markup.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098154
2010-03-03 00:15:26 +00:00
Volker Lanz a383d17f75 don't read the new partition table's type name from the device's partition
table: it might not yet have been set to the new partition table and thus this
will either be wrong or even crash if the device doesn't have a partition table
at all

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1097709
2010-03-01 22:48:23 +00:00
Volker Lanz 1e2a852df9 remove all traces of libparted from the main binary and lib
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1097708
2010-03-01 22:42:52 +00:00
Volker Lanz 8bc47ee964 rename any occurences of "disk label" to partition table for consistency
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1095455
2010-02-24 11:32:12 +00:00
Volker Lanz df26044041 rename LibParted class to LibPartedBackend (plus files)
introduce a CoreBackend superclass for all future backends


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1095129
2010-02-23 18:04:45 +00:00
Volker Lanz c809be064a begin work on new disk label type for msdos(vista)
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1083614
2010-02-01 16:32:45 +00:00
Volker Lanz 7d90e9f78d don't assume on creating a new partition table that the existing partition
table will be able to inform us about first and last usable sector... need to
have some defaults here.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1082202
2010-01-29 23:20:22 +00:00
Volker Lanz c2f127d903 make GPT support work: account for GPT writing a copy of its meta information
to the end of the device, thus requiring us to leave some free space at the end

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1082076
2010-01-29 16:41:42 +00:00
Volker Lanz 87f2f41e1f add basic support for GPT disk labels
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1081931
2010-01-29 11:25:28 +00:00
Volker Lanz 44af166f83 rename all values in CommandSupportType to make them more unique
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1081018
2010-01-27 13:00:14 +00:00
Volker Lanz 908bfe3669 add "shred partition" feature
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1076584
2010-01-18 12:31:00 +00:00
Volker Lanz 3dce0a78aa clean ups: whitespace, add some q_disable_copy macros, add props to class
headers

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1046695
2009-11-09 14:00:36 +00:00
Volker Lanz e9b3eccd5d Clear the partition flags for a copied partition.
BUG: 202346

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1005968
2009-08-02 18:32:33 +00:00
Volker Lanz 2499c31527 Set the number of used sectors on a newly created FS to -1.
BUG: 199710

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=995188
2009-07-12 09:46:43 +00:00
Volker Lanz 306667e09e Don't assume a device always has a valid partition table. This is the correct
fix for what I initially tried to fix with commit 898001.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=908045
2009-01-09 07:10:59 +00:00
Volker Lanz 70766b856e fix undoing create new partition table: if the "old" partition table is empty,
don't insert unallocated space as it is invalid; insert unallocated space in
the ctor for the create partition table op instead where it's always the
correct thing to do.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=898001
2008-12-17 11:23:30 +00:00
Volker Lanz d611536684 Fix warnings in gcc 4.3
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=887192
2008-11-21 12:28:39 +00:00
Allen Winter fcaa2c7586 fix include guards. found while I was testing krazy false positive fixes
svn path=/trunk/playground/sysadmin/partitionmanager/; revision=869633
2008-10-09 14:44:32 +00:00
Volker Lanz 26d914e7c8 Don't allow creating a new partition table on a device with currently mounted
partitions.

svn path=/trunk/playground/sysadmin/partitionmanager/; revision=868375
2008-10-06 07:31:11 +00:00
Laurent Montel 4d1c7f2d04 Pedantic
svn path=/trunk/playground/sysadmin/partitionmanager/; revision=864677
2008-09-25 11:53:41 +00:00
Volker Lanz d6dc26bd90 import of KDE Partition Manager
svn path=/trunk/playground/sysadmin/partitionmanager/; revision=864431
2008-09-24 19:32:01 +00:00