Commit Graph

621 Commits

Author SHA1 Message Date
Andrius Štikonas 2790b430bb Allow setting labels during creation of LUKS volume. 2016-04-24 17:48:24 +01:00
Teo Mrnjavac 221c375bd4 Rookie mistake. 2016-04-21 19:30:18 +02:00
Teo Mrnjavac 9a8dc0127d Force show the passphrase widgets. 2016-04-21 19:25:53 +02:00
Teo Mrnjavac 1e300afbac Correctly hide passphrase widget. 2016-04-21 19:21:34 +02:00
Teo Mrnjavac f56539a4b0 Revert "Do not delete checkbox and passprase widget objects."
This reverts commit 2bed9f23eb.
2016-04-21 18:44:25 +02:00
Teo Mrnjavac 5fc1683672 Don't crash on resize dialog. 2016-04-21 18:43:54 +02:00
Andrius Štikonas 2bed9f23eb
Do not delete checkbox and passprase widget objects.
Workarounds a crash when resizing LUKS partitions.
2016-04-21 17:37:49 +01:00
Teo Mrnjavac a1b886578f Set the passphrase on FS::luks. 2016-04-21 17:57:25 +02:00
Teo Mrnjavac 5f3a0ca691 Hide it by default. 2016-04-21 17:56:55 +02:00
Teo Mrnjavac 0c065cd786 Add passphrase widget to create dialog. 2016-04-21 17:56:44 +02:00
Teo Mrnjavac 64668df117 Avoid using exceptions, again. 2016-04-20 15:15:01 +02:00
Teo Mrnjavac 1b958db71f Avoid using exceptions. 2016-04-20 14:46:22 +02:00
Teo Mrnjavac cf4d687d54 Rely on the partition role instead of the filesystem type. 2016-04-19 17:08:01 +02:00
Teo Mrnjavac 29d3a92805 Use the role instead of the filesystem type to detect a LUKS volume. 2016-04-19 16:54:33 +02:00
Teo Mrnjavac 03d3925775 PartitionRole::LUKS is now PartitionRole::Luks. 2016-04-19 16:53:56 +02:00
Andrius Štikonas ad64f7537b
Rename qglobal.h to QtGlobal 2016-04-18 17:17:19 +01:00
Andrius Štikonas f878865aa0
Merge branch 'master' into luks-decorator 2016-04-16 00:34:50 +01:00
Andrius Štikonas b3303ee6bf
Fix LUKS encryption support for filesystems without support for writing label.
This enables LUKS encryption for Reiser4 and LVM PV.
2016-04-16 00:28:14 +01:00
Teo Mrnjavac 13031913f4 Update copyrights. 2016-04-15 15:45:22 +02:00
Teo Mrnjavac 46baf7c440 Create FS as inner FS in LUKS if the encrypt setting is checked.
Filter out LUKS from FS combo.
2016-04-15 15:38:11 +02:00
Teo Mrnjavac c67911c0d2 Hide LUKS checkBox by default. 2016-04-15 15:36:41 +02:00
Teo Mrnjavac b0b2eccc23 Add "Encrypt" checkBox to partition widget.
Also replace occurrences of NULL with nullptr.
2016-04-15 15:35:45 +02:00
Andrius Štikonas cf891183cb
Always use because it is type safe. 2016-04-14 19:18:36 +01:00
Teo Mrnjavac 0c780279ae Resurrect LUKS code which was previously merged+reverted.
Revert "Revert "Merge branch 'luks-decorator'""

This reverts commit 6806de6fb7.
2016-03-31 18:20:57 +02:00
Andrius Štikonas 9c91e25e96 Update copyright. 2016-03-02 18:33:40 +00:00
Teo Mrnjavac 97175c71ad Fix bug with EditMountPointDialog not having Ok&Cancel buttons. 2016-02-29 01:11:10 +00:00
Andrius Štikonas c140e6665f Fix checkSupportInNode for extended partitions (disables bogus warning). 2016-02-29 01:05:39 +00:00
Teo Mrnjavac 5e7c9f7131 Fix crash when applying settings. 2016-02-26 15:32:14 +01:00
Andrius Štikonas d2a013222e Use KLocalizeStrings to avoid nested xi18n calls.
Nested xi18n calls cause QStrings to be escaped and makes HTML
visible in KMessageBox.

BUG: 354925
2016-02-18 14:59:59 +00:00
Andrius Štikonas 15b7fa3470 kpmcore/ prefix in #includes is no longer required. 2016-01-12 00:12:49 +00:00
Andrius Štikonas 333e03ac10 Get rid of kpmgui internal library.
kpmgui was basically the whole partitionmanager except for main.cpp file.
All useful functions were moved to kpmcore library, kpmgui is not necessary now.
2016-01-06 15:56:32 +02:00
Andrius Štikonas 6806de6fb7 Revert "Merge branch 'luks-decorator'"
This reverts commit 54ce33b472, reversing
changes made to 98d08a81c5.
2015-09-16 14:14:53 +01:00
Teo Mrnjavac a88ceb2140 Fix bug with EditMountPointDialog not having Ok&Cancel buttons. 2015-08-14 18:07:26 +02:00
Teo Mrnjavac 65ffb182c5 Hook up new LUKS functionality from KPMcore.
Add decrypt action to actionCollection and context menu.
Wrap very long lines.
Replace NULL with nullptr, TODO: do this everywhere.
2015-08-14 17:57:27 +02:00
Teo Mrnjavac 6e1ff468d3 Set partition color code on PartWidget, and react to settings change. 2015-07-17 13:37:30 +02:00
Teo Mrnjavac 9d9a2b345a Make sure sectorAlignment is set. 2015-07-15 19:03:39 +02:00
Andrius Štikonas 81004a2445 Format partitionmanager code using KDE style. 2015-07-13 17:17:41 +03:00
Teo Mrnjavac 94bae2494f Fix indentation. 2015-07-13 15:50:45 +02:00
Teo Mrnjavac 23084a258d Specify default filesystem type when creating new partition. 2015-07-13 15:33:45 +02:00
Teo Mrnjavac c0381cd913 Read Shred action from KConfig. 2015-07-10 15:57:02 +02:00
Teo Mrnjavac cf51fa1ad0 Move PartResizerWidget and related to KPMcore. 2015-07-08 18:16:03 +02:00
Andrius Štikonas 618468742c Move FileSystem::defaultFileSystem to GUI. 2015-06-30 22:22:13 +03:00
Andrius Štikonas a58a041e6a Move Capacity::preferredUnit to GUI. 2015-06-14 02:06:18 +01:00
Andrius Štikonas 11b097141a Move createFileSystemColor back to GUI. 2015-06-12 13:11:29 +01:00
Andrius Štikonas b651d8de89 Move kpmcore to another repository (sysadmin/kpmcore) 2015-06-04 01:51:56 +01:00
Andrius Štikonas 9d135978ad Add HiDPI support. 2015-04-09 23:26:52 +03:00
Andrius Štikonas 8e5c1b1ebd Move naturalLessThan function out of util/helpers. 2015-03-28 16:56:39 +00:00
Andrius Štikonas 93f6bcdc83 Generate export header for libkpmgui. 2015-03-28 00:43:38 +00:00
Chris Campbell 0ff2c923c3 Split partitionmanagerprivate into kpmcore and kpmgui.
Please enter the commit message for your changes. Lines starting
2015-03-27 16:28:21 +00:00
Andrius Štikonas bbb2fa3067 Use GPLv3 copyright notices. 2015-02-07 00:32:25 +00:00
Andrius Štikonas 97baf57d67 Fix size constrains of extendable part of sizedialog. 2015-02-05 10:37:50 +00:00
Andrius Štikonas d52ea34cf7 Complete KF5 port:
* Expose backend versions in a similar manner to backend Id.
 * Fix configure dialog signals.
2015-02-05 00:09:39 +00:00
Teo Mrnjavac aa132e1cdb Try to port backend loading away from KAboutData. 2015-02-03 19:53:46 +01:00
Yuri Chornoivan b44042a200 Fix tags 2014-11-30 11:52:13 +02:00
Andrius Štikonas 109d35d9f4 Fix build. 2014-11-19 12:05:22 +00:00
Andrius Štikonas cc8e02cb43 Port away from deprecated KF5 methods. 2014-11-03 19:57:25 +00:00
Aurélien Gâteau b313365276 Remove stray kcolorscheme.h include 2014-08-08 20:28:49 +03:00
Aurélien Gâteau a9cd6ae885 Draw the border around the handles
Otherwise they are difficult to see when the partition takes all the space
2014-08-08 20:28:49 +03:00
Aurélien Gâteau 40f579a811 PartResizerWidget: Render the background using a QLineEdit
This is more readable when style is not Oxygen
2014-08-08 20:28:49 +03:00
Andrius Štikonas debfbade66 Display KDE Frameworks (KXmlGui) version. 2014-05-29 12:52:33 +01:00
Andrius Štikonas f78c34778e Make shredSource radio button work again. 2014-05-29 02:45:36 +01:00
Andrius Štikonas 7fbae9ee29 Port to new Qt5 macro QStringLiteral and use stricter compile flags
Now compile with:
  -DQT_USE_QSTRINGBUILDER
  -DQT_NO_CAST_TO_ASCII
  -DQT_NO_CAST_FROM_ASCII
  -DQT_STRICT_ITERATORS
  -DQT_NO_URL_CAST_FROM_STRING
  -DQT_NO_CAST_FROM_BYTEARRAY
  -DQT_NO_SIGNALS_SLOTS_KEYWORDS
  -DQT_USE_FAST_OPERATOR_PLUS
2014-05-20 22:33:02 +01:00
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 5eb2a06da4 Use QLocale().toString instead of KGlobal::locale() 2014-05-18 16:55:29 +01:00
Andrius Štikonas d1ae9dc4a7 Port away from KMenu. 2014-05-17 03:20:43 +01:00
Andrius Štikonas 81ce940171 Port away from KAction. 2014-05-17 03:12:10 +01:00
Andrius Štikonas dcdffadc3e Port away from KDialog. 2014-05-17 03:06:58 +01:00
Andrius Štikonas 066cd120e7 Partially port away from KIcon. 2014-05-17 02:27:42 +01:00
Andrius Štikonas a490106e75 Port away from KTextEdit. 2014-05-17 02:14:18 +01:00
Andrius Štikonas 14e9ecb779 Port away from KLineEdit, KPushButton and KComboBox. 2014-05-14 01:01:34 +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 b2d299e18d Port away from KDebug.
Replace a few more kWarning() that were missed in the last commit.
2014-05-13 23:52:54 +01:00
Andrius Štikonas 2b537490ad Port away from KDebug. 2014-05-13 14:47:35 +01:00
Andrius Štikonas 2b75f43bb0 Support for decrypting LUKS volumes.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1362680
2013-08-09 19:25:48 +00: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 084c604c3c Make filesystem label length depend on file system.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1330603
2013-01-03 12:43:03 +00:00
Volker Lanz 6ab19a9c49 Remove unused slot for menu-bar-removal warning.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1329474
2012-12-22 12:29:36 +00:00
Volker Lanz 0336c4635d fix wrong/outdated doxygen comment for ctor
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1328194
2012-12-12 00:12:30 +00:00
Andrius Štikonas ebf4c75855 Don't draw resize handles for unresizable partitions.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1328017
2012-12-10 18:38:55 +00:00
Andrius Štikonas 298fcf1772 Set unresizable partitions as read only.
BUG:310632

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1327840
2012-12-09 15:54:22 +00:00
Andrius Štikonas c93da7c1ae Use fileSystem().type() to avoid string comparison.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1325825
2012-11-21 18:38:41 +00:00
Andrius Štikonas 39dc9c5c46 Print more info about LUKS partitions in the infopane.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1325759
2012-11-21 00:54:04 +00:00
Volker Lanz 9b33918f08 Remove wrong todo: The resize dialog does indeed have a
dirty bit.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1324098
2012-11-05 10:19:27 +00:00
Volker Lanz 7ee70cf9bd Don't offer action to hide menu bar, it's a trap.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1324070
2012-11-05 09:25:27 +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 d80b35382f log backend plugin and version when scanning devices. generally not a bad idea,
but currently required to make sure we run with the correct libparted version
during development.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1274437
2012-01-18 11:17:25 +00:00
Volker Lanz 1002424cf7 another year...
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1274434
2012-01-18 11:03:06 +00:00
Volker Lanz eb8422e1a7 fix weird formatting
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1274433
2012-01-18 11:02:35 +00:00
Volker Lanz 8c25f446c8 naturally sort the list of devices we have no fs-support for
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1236306
2011-06-12 09:33:11 +00:00
Albert Astals Cid c934fa5daa Convert these extracomment to comment
Because:
 * We have a bug in our scripts that makes extracomment not work (will try to fix this asap)
 * Makes sense to be a comment since we want it to be a disambiguation text
 * KUIT markers (e.g. @label) need to be in comment     

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1231324
2011-05-10 22:22:58 +00:00
Volker Lanz 92859b3aa5 use plastique as a fallback style if user is running GTK style so the part
widget display is ok.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1226198
2011-03-27 16:44:29 +00:00
Volker Lanz fd3105a50a Fix double margins and set margins to zero for the panel layouts where it makes
sense. Spotted and original patch provided by Aurélien Gâteau
<agateau@kde.org>. Thanks!

CCMAIL:agateau@kde.org

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1226196
2011-03-27 16:26:45 +00:00
Pino Toscano 9636acce06 fixuifiles
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1196188
2010-11-12 19:04:52 +00:00
Volker Lanz c4d159e6c5 krazy2 fixes
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1160573
2010-08-08 12:36:05 +00:00
Volker Lanz fe6f80379a make sure not to return false when isSectorBase() is called more than once.
make the heuristic to determine if a partition table is sector aligned a little
less dumb.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1140829
2010-06-21 15:49:53 +00:00
Volker Lanz 84699a502f set all partwidgets to 60px in height
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1140817
2010-06-21 15:23:24 +00:00
Volker Lanz 9270dec7b2 remove debug output
align start and end when initializing the dialog if align is on

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1140811
2010-06-21 15:15:19 +00:00
Volker Lanz 75e79e354c set mouseover state for active partition
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136709
2010-06-10 14:09:04 +00:00
Volker Lanz 900e58dd59 try and make the selected partition more distinct; also use white to write the
partition info for the selected partition.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136461
2010-06-09 22:50:42 +00:00
Volker Lanz 083adc23fa fix ws and some small logic simplification
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136453
2010-06-09 22:00:28 +00:00
Hugo Pereira Da Costa 9d8796e83d added one _horizontal_ missing pixel to the frame, to cope with changes in partWidget painting
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136104
2010-06-08 23:10:18 +00:00
Hugo Pereira Da Costa 346117868d added one missing pixel to the frame, to cope with changes in partWidget painting
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136102
2010-06-08 23:07:58 +00:00
Hugo Pereira Da Costa d42914443d Re-added painting of unallocated space.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136099
2010-06-08 22:57:56 +00:00
Hugo Pereira Da Costa 38d035b235 removed the unused '-1' from rect sizes calculation
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136097
2010-06-08 22:54:13 +00:00
Hugo Pereira Da Costa b97126b5e4 Set borderwidth and borderheight to zero for parttablewidget.h
Set the margin of partitionmanagerwidgetbase to zero. And reduced the fixed height from 80 to 74, to account for the change above.



svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136095
2010-06-08 22:45:31 +00:00
Hugo Pereira Da Costa 8f0e9c270d Moved borderWidth, borderHeight, and positionChildren from static to virtual.
This way they can be reimplemented in subclasses.


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136094
2010-06-08 22:43:59 +00:00
Hugo Pereira Da Costa 57cd2870d7 Remove painting of free and used- space on top of partition rect.
Use two different rects for the partition rect instead, with colors calculated from the base color derived from the partition type.



svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1136093
2010-06-08 22:38:27 +00:00
Volker Lanz 771ee3cb5c use same horizontal stretch as dialogbase
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135948
2010-06-08 13:23:29 +00:00
Volker Lanz c0f1b0123a show physical sector size in GUI
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135558
2010-06-07 15:37:20 +00:00
Volker Lanz 7bde47b854 rename sector size labels in DevicePropsWidget (and its UI file) to logical
sector size

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135518
2010-06-07 13:42:19 +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 7c750514d0 make sure to say we're talking about logical sector size when we say sector size.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135497
2010-06-07 12:56:27 +00:00
Volker Lanz d18e8cfb2a fix horizontal stretch
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135478
2010-06-07 12:14:55 +00:00
Volker Lanz fa36ef13f6 simplyfy grid layout, fix horizontal stretch
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135474
2010-06-07 12:20:03 +00:00
Volker Lanz ecb6341769 fix horizontal stretch
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135470
2010-06-07 12:11:31 +00:00
Volker Lanz 3b2a443e07 modify spacing, width and border size for new looks
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135253
2010-06-06 23:39:10 +00:00
Volker Lanz 29f73d29fa integrate Hugo's new code a little better, mainly white space.
move implementation of handleWidget() to cpp file to avoid an include

add credit to KAboutData

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135182
2010-06-06 18:23:17 +00:00
Hugo Pereira Da Costa 16de8b9034 Changed rendering of
- partwidget, to use the same appearance as buttons
- partresizewidget, to use a 'sunken' frame, and same appearance as QSplitter for the resize handlers.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1135173
2010-06-06 17:57:08 +00:00
Volker Lanz 68d1eb14ce use a PartWidget instead of a PartResizerWidget in the partition properties
dialog -- no one is going to do any resizing, after all.

to make this possible, allow creating a PartWidget() without a valid Partition
pointer and add an init() method for later setting the Partition pointer. also
take care of the Partition pointer being NULL everywhere in the class

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1134172
2010-06-03 15:01:53 +00:00
Volker Lanz 6508ad1d71 create and handle info pane just like the other dock widget content widgets
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1134148
2010-06-03 14:27:11 +00:00
Volker Lanz 0a77bb6d8a remove KPart remains
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1134137
2010-06-03 14:02:35 +00:00
Volker Lanz 358825fba1 move mountentry to its own implementation files and make it a class
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1133534
2010-06-01 22:07:13 +00:00
Volker Lanz a6715ebebe increase version
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1133462
2010-06-01 19:21:50 +00:00
Volker Lanz b47363f3a2 remove some actions from default toolbars to make them more usable
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1133421
2010-06-01 17:52:53 +00:00
Volker Lanz bd3a3db8b9 make sure the max value of first and last sector isn't set wrong
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1132901
2010-05-31 17:12:18 +00:00
Volker Lanz e66fa24e52 don't allow editing mount points for mounted partitions
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1130885
2010-05-26 17:33:39 +00:00
Volker Lanz b7dfc67ca9 resolve symlinks when reading device nodes from fstab
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1130866
2010-05-26 16:52:20 +00:00
Volker Lanz 51ae5ddcb4 clear the clipboard if undo deleted the partition that's in it
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129877
2010-05-24 01:52:36 +00:00
Volker Lanz 91b6ce0a47 make formatted spinbox work when suffix or prefix are set
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129714
2010-05-23 14:05:57 +00:00
Volker Lanz f9c0fcd0b3 don't crash checkinf file system support if no partition table is present
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1129264
2010-05-21 19:52:22 +00:00
Volker Lanz 08da1fac60 move FileSystemSupportDialogWidget to a file of its own
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128905
2010-05-20 16:09:29 +00:00
Volker Lanz bdfce5576f delete delgate in dtor
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128892
2010-05-20 15:38:15 +00:00
Volker Lanz e9871e0e82 add a check when scanning devices if support for all file systems we found is
present. if not, show a messagebox with detailed information what is missing.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128887
2010-05-20 15:25:55 +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 696b368463 add a select device submenu to the device menu
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128594
2010-05-19 18:39:40 +00:00
Volker Lanz d8d7b82862 use pretty name from Device class
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128593
2010-05-19 18:38:32 +00:00
Volker Lanz 6b260d97ec use pretty print method from Device
output device name in bold

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128592
2010-05-19 18:38:00 +00:00
Volker Lanz 8b912ffb88 prevent the user from pasting a partition on another that is too big for the
source partition's file system

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128581
2010-05-19 17:38:12 +00:00
Volker Lanz 2b1f937917 warn if user tries to overwrite an existing partition with another or an image
file

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1128576
2010-05-19 17:11:15 +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 2069e191de make sure to update unallocated space after changing the alignment type. also,
update partition widget after changing the alignment type since now the
unallocated space might have changed.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127793
2010-05-17 16:36:18 +00:00
Volker Lanz 2202629829 ws fix
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127770
2010-05-17 15:50:10 +00:00
Volker Lanz 3eb9dc8b4a add assert and check if there is a selected partition
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127769
2010-05-17 15:49:46 +00:00
Volker Lanz 438a325f29 neither KMountPoint nor our own edit mount point dialog can handle more than
one mount point per partition, so don't pretend we could in the Partition class

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127763
2010-05-17 15:17:15 +00:00
Volker Lanz bc5d916cc6 if the target file does not exist, don't complain if we cannot rename it to a
backup

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127762
2010-05-17 15:14:19 +00:00
Volker Lanz bff6424cf6 check if the mount point the partition has is non-empty before using it in the
dialog.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127371
2010-05-16 12:19:04 +00:00
Volker Lanz 96964cc52d make sure avail and used capacity aren't printed if not known
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1127356
2010-05-16 11:45:31 +00:00
Volker Lanz d9715e5211 switch the order of file system and label so it's consistent across dialogs
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1122705
2010-05-04 14:27:12 +00:00
Volker Lanz 0c3f5ca46f add icons to open browser and save buttons
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1121503
2010-05-01 13:31:27 +00:00
Volker Lanz df7ef8571d make HtmlReport a real class
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1121500
2010-05-01 13:19:50 +00:00
Volker Lanz ce6f2c08d4 add a first version of a html report class
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1120179
2010-04-28 15:21:07 +00:00
Volker Lanz bc58e08b93 add saving of smart report to a html file
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119675
2010-04-27 16:10:54 +00:00
Volker Lanz a26bda1ca8 re-init the file systems when loading a new backend
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119646
2010-04-27 14:49:28 +00:00
Volker Lanz 1c97342be3 if the file system we want to set the combo box to cannot be found in it, set
it to the first value; don't set it to -1

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119609
2010-04-27 13:19:34 +00:00
Volker Lanz 0bc6695513 remove the NO_THREADED_DEVICE_SCANNER ifdefs, they are not requires anymore
(and never really were)

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119568
2010-04-27 12:14:53 +00:00
Volker Lanz 19ed42c34b make sure we hide the scan progress dialog even if there is no progress at all
(most likely the case when there are no devices found at all)

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119566
2010-04-27 12:11:50 +00:00
Volker Lanz f8e81095ea add a formatted spin box
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119557
2010-04-27 11:41:35 +00:00
Volker Lanz 004e83447b turn off keyboard tracking for the spin boxes if align is on; this mostly
alleviates the problems arising from overwriting the spin box values if the new
value is illegal since we don't see values while they are being entered

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119551
2010-04-27 11:21:16 +00:00
Volker Lanz b28c212a9d make the spin boxes in SizeDialogBase work properly with aligned partitions,
mostly.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119547
2010-04-27 11:04:59 +00:00
Volker Lanz d08ce3ac78 move the updateLength-code from the part resizer widget to SizeDialogBase
because that's where it's actually being used exclusively.

don't update the spinbox value in
SizeDialogBase::onFreeSpaceBefore/AfterChanged() because if we do that the user
cannot enter values digit by digit anymore (we'll just overwrite what he entered
after each keystroke)

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119113
2010-04-26 15:37:02 +00:00
Volker Lanz 80cbafc7cb set spin box stepping for capacity, too
make sure we set the correct value for the free space spinboxes after
calculating the new first/last sector

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119091
2010-04-26 14:34:59 +00:00
Volker Lanz 1322c015e0 make sure start and end are aligned when updating a partition's length
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119081
2010-04-26 14:14:14 +00:00
Volker Lanz 42cc630639 update TODO
don't check for length constraints when moving a partition: the length must not
change anyway and the logic wouldn't work because the length DOES change in
between calls to update first and last sector

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119076
2010-04-26 14:03:41 +00:00
Volker Lanz 0284f685a8 make PartitionAlignment::alignedFirstSector() and
PartitionAlignment::alignedLastSector() take the min and max first/last, the
min length and the max length as args, making a lot of stuff in
PartitionAlignment superfluous.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119051
2010-04-26 13:14:29 +00:00
Volker Lanz b6f60697e9 no need to align new or inserted partitions: they're replacing unallocated or
existing partitions which will be aligned if that is what the user configured

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119049
2010-04-26 13:12:48 +00:00
Volker Lanz 32f610d28a make changing the free space after a partition work with aligning, mostly.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119010
2010-04-26 11:46:38 +00:00
Volker Lanz 6b89377253 make changing the free space before a partition work with aligning, mostly.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119007
2010-04-26 11:30:06 +00:00
Volker Lanz 31936a5072 set maximum for sector
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1119006
2010-04-26 11:24:51 +00:00
Volker Lanz 8dcd4cd1de use QDoubleSpinBox instead of the integer version for free space before and
after and for capacity so that fractions are possible for these values

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1118931
2010-04-26 08:50:57 +00:00
Laurent Montel 444cc70394 Fix ui files
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1116400
2010-04-19 11:47:04 +00:00
Volker Lanz d4772c37fb make resizeLogicals take start and end delta as args to it does not always have
to delete and re-create the unallocated first and last child in an extended
partition, which is a waste of resources

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1116005
2010-04-18 11:36:00 +00:00
Volker Lanz 1747d31bd2 fix setupDialog and setupConstraints in SizeDialogBase and reverse the order
they're called in in the various dialog ctors to how it was in 1.0.x (which
makes a lot more sense)

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115388
2010-04-16 09:28:39 +00:00
Volker Lanz 5e6b74e1af use the setters in init() for readonly and move allowed; also, call the setters
in the order the args are in

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115387
2010-04-16 09:27:39 +00:00
Volker Lanz 511c20476c fix off by one
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115384
2010-04-16 09:05:08 +00:00
Volker Lanz 50ee02a24a fix calculation of min and max first and last for aligned case
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115379
2010-04-16 08:40:33 +00:00
Volker Lanz 34842c84cb make PartResizerWidget::resizeLogicals do the "right" thing for non extended
partitions (i.e., just remove any children)

call resizeLogicals() when a new partition's role changes in NewDialog so it
gets an unallocated child if it's now extended or the unallocated child is
removed if not anymore.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115223
2010-04-15 16:59:56 +00:00
Volker Lanz 8632b7cf0d Move the workaround-code that replaced making a temp copy of a partition for
the ResizeDialog to said dialog instead of cluttering the
PartitionManagetWidget's call with that.

Call updatePartitions() after exec'ing ResizeDialog() even if the dialog was
not accepted as it might have deleted and re-created unallocated children of
extended partitions anyway -- and that would crash us later.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115191
2010-04-15 15:30:08 +00:00
Volker Lanz 0bebc1a2d0 Don't update logicals when moving an extended partition:
Moving extended partitions is not allowed if they have logicals and calling the
resizeLogicals() method will remove the unallocated partition the user has with
an 98% probability clicked to drag from under our feet, causing moving to fail.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115167
2010-04-15 14:25:55 +00:00
Volker Lanz ee5f16ad34 don't crash when creating a size dialog: don't set moveAllowed before the
partWidget is created

make sure to always create unallocated partitions when resizing an extended,
not only if it already has one.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115158
2010-04-15 13:41:12 +00:00
Volker Lanz ca76d30c3d Align a partition if it's newly created (or inserted), the one it replaces
was not aligned and aligning is on.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115135
2010-04-15 10:46:36 +00:00
Volker Lanz ee40f89db7 Make PartitionAlignment a shell around static methods only.
Make sure aligning partitions actually works in the part resizer. Could still
need work and even thought.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115134
2010-04-15 10:45:43 +00:00
Volker Lanz 9436c18f69 Do not create a temporary Partition instance for resizing. This does not work
anymore because when aligning the resized partition it is no longer known if an
existing partition is the source of the temporary copy or some other partition.

Let the ResizeDialog modify the original and restore its start and end sector
after the dialog has been executed instead.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115133
2010-04-15 10:38:48 +00:00
Volker Lanz 82f08a4f8b use PartitionAlignment::sectorAlignment, not Config::sectorAlignment
let the PartResizerWidget know the state of the align checkbox

use the toggled, not the stateChanged signal from the align checkbox

make sure PartResizerWidget::setMoveAllowed is called before PartResizerWidget::init


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115131
2010-04-15 10:32:12 +00:00
Volker Lanz 65500ac0f3 change arg name so it doesn't clash with a method name
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1115130
2010-04-15 10:26:51 +00:00
Volker Lanz 9426e3afec add new class PartitionAlignment and move all alignment related stuff there
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114380
2010-04-13 10:04:01 +00:00
Volker Lanz 3d6b74453e check the constraints (first and last sector min and max) again after aligning
a partition to make sure we're not going over those. of course
PartitionTable::alignPartition() shouldn't move first and last sector to
anywhere it's not allowed to, but currently it seems buggy enough to do so and
the check won't hurt.

PartitionTable::alignPartition() still needs to be fixed, of course.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114084
2010-04-12 18:20:14 +00:00
Volker Lanz d349fbd591 don't try to move a partition if first sector or last sector don't change
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114076
2010-04-12 17:51:21 +00:00
Volker Lanz f1bc4afde8 also set PartWidgets to visible
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114071
2010-04-12 17:29:29 +00:00
Volker Lanz ea2e6cba9f move more code from setupConstraints to setupDialog as another workaround. this
really needs fixing.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114067
2010-04-12 17:05:10 +00:00
Volker Lanz ec44af261e move childWidgets() from PartWidget and PartTableWidget to the common base
class

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114051
2010-04-12 16:22:14 +00:00
Volker Lanz 92a9bd2878 make PartWidgetBase a QWidget
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114049
2010-04-12 16:14:10 +00:00
Volker Lanz 22978e66b8 don't keep a list of our children in PartTableWidget either; like in
PartWidget, we can just let Qt handle that for us

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114047
2010-04-12 16:08:13 +00:00
Volker Lanz c1a6713e45 Remember the active PartWidget in the widget, not in the PartTableWidget. This
means the PartWidget doesn't need to know its PartTableWidget anymore.

Don't keep a list of child widgets, Qt will do that for us.

Remove the showChildren param and property from PartWidget, it wasn't used
anymore.

Rename active() to isActive() in PartWidget for consistency.


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1114033
2010-04-12 14:35:02 +00:00
Volker Lanz 3f1b211df9 no one is calling the code in drawPartition() but the paint event so move it to
the paint event handler. also, remove a superflous assert in the ctor.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113987
2010-04-12 12:48:17 +00:00
Volker Lanz 0d2f3ccc84 clean up partwidget class: don't use qpointers, don't use a pointer for access
to the partition property. still needs more work.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113951
2010-04-12 10:55:13 +00:00
Volker Lanz f2e216cb43 check if there actually is a partition in the partwidget before accessing it
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113935
2010-04-12 10:15:30 +00:00
Volker Lanz 72775ba8a0 this is surely const
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113930
2010-04-12 09:45:14 +00:00
Volker Lanz aabeab1d54 show an ok-icon if smart status is ok and hide the icon label if smart status
is unknown

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113927
2010-04-12 09:23:55 +00:00
Volker Lanz 6d8192b18e use the icons the kstandardguiitem would use in all kguiitems we create
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113772
2010-04-11 18:19:24 +00:00
Volker Lanz 2f822dd21b check if device has more than 2^32 sectors if user wants to create an msdos
partition table on it and show a warning in that case. also make the default
GPT.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113771
2010-04-11 18:06:47 +00:00
Volker Lanz cf9ecebd1f turns out which sector alignment is used on import is determined by the app
wide default in the settings. well. for now, include the information in the
export, but ignore it on import.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113752
2010-04-11 17:16:43 +00:00
Volker Lanz 10bc881dfd use KIO for file IO where appropriate
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113737
2010-04-11 16:12:16 +00:00
Volker Lanz 216868d8ee use KTemporaryFile
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113723
2010-04-11 15:41:35 +00:00
Volker Lanz 4180318c41 remove kdebug line we apparently forgot to remove ;-)
use KIO to save files (actually, use a temp file and copy it with KIO::move)


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1113694
2010-04-11 14:29:20 +00:00
Volker Lanz 180fa4643d extend smart stuff, add its own dialog, add action to trigger it etc.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1108004
2010-03-27 13:47:32 +00:00
Volker Lanz c29ce45cc8 add an icon if the smart status is bad
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1107721
2010-03-26 16:02:55 +00:00
Volker Lanz 28efbee2ec add smart status information
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1107708
2010-03-26 15:06:33 +00:00
Volker Lanz 10efee63d1 don't add, subtract from the new first sector to make minimum size work
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1107491
2010-03-25 19:58:35 +00:00
Volker Lanz 6b4aa38bcd replace numPendingOperations() with operationStack().size()
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1107160
2010-03-24 23:32:20 +00:00
Volker Lanz 74db24753b warn if user changes backend and operations are pending
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1107157
2010-03-24 23:30:20 +00:00
Volker Lanz b28a66bc3f don't assume idx 0 is the default file system
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1106842
2010-03-24 00:20:35 +00:00
Volker Lanz 40ae70af25 move config stuff to its own src subdir
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1105772
2010-03-21 11:32:31 +00:00
Volker Lanz 5ca58c6c1c introduce a CoreBackendManager class.
convert the plugins into true KDE plugins with desktop file and all.

let the user pick a backend in the config dialog and load backends on the fly.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1105758
2010-03-21 10:50:44 +00:00
Volker Lanz e3932ebf3f use "Advanced" as button text for the details button
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1105464
2010-03-20 10:10:11 +00:00
Volker Lanz 36dccf2c55 new text for "align partition" checkbox
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1105449
2010-03-20 08:56:01 +00:00
Volker Lanz 791377f176 only return true from PartResizerWidget::movePartition() if the partition was
actually moved.

set single step for the sector spinboxes to align value

add a checkbox to turn off aligning the partition


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1105207
2010-03-19 14:13:04 +00:00
Volker Lanz edca30b707 add a details widget for the size dialog base and use it for first and last
sector

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1104707
2010-03-18 11:04:13 +00:00
Volker Lanz a892c765cb use a qdoublespinbox instead of a qspinbox for sectors so values higher than
2^31 fit

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1104299
2010-03-17 10:48:24 +00:00
Volker Lanz c384fdaf21 refactor the part resizer and the size dialog base so they're less ugly, less
confusing and don't use free sectors before and after the partition but just
plain start and end.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1103958
2010-03-16 11:40:54 +00:00
Laurent Montel 0b456bcfcc Fix ui files
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1103483
2010-03-15 08:28:53 +00:00
Volker Lanz 537108c78f simplify dialog
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102174
2010-03-11 23:51:10 +00:00
Volker Lanz 3ab91021c1 make sure to show the right fs color even for extended partitions in the
new-partition-dialog

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102170
2010-03-11 23:33:41 +00:00
Volker Lanz 9091e883e6 handle default button for custom widgets in configure dialog
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102086
2010-03-11 19:40:42 +00:00
Volker Lanz d013c6d386 add default value and single step of 512 to sector alignment
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102066
2010-03-11 18:45:21 +00:00
Volker Lanz 7ebfbdb597 remove amps from kguiitems in message boxes, let KDE handle shortcuts
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102034
2010-03-11 16:55:27 +00:00
Volker Lanz 54def83c4e wording fix
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102031
2010-03-11 16:45:59 +00:00
Volker Lanz f2f55e00fa improve wording
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102027
2010-03-11 16:43:00 +00:00
Volker Lanz 34278260f3 some wording and i18n fixes.
don't use amp in ui files, let KDE figure out the shortcuts in dialogs

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1102025
2010-03-11 16:34:48 +00:00
Volker Lanz ebf1612dc8 add setting of default FS to config dialog
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1101986
2010-03-11 14:17:21 +00:00
Volker Lanz 867ca54aca use configure icon, not app icon, for general settings page
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1101339
2010-03-09 22:39:03 +00:00
Volker Lanz 2e7510e816 add visibility to the config class
create an instance of the config in main() instead of the main window.

configure the backend plugin to load via the config file

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1101230
2010-03-09 17:13:22 +00:00
Volker Lanz 156dcf9e33 add some i18n comments to make clearer what the header text is supposed to mean
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1100689
2010-03-08 10:28:00 +00:00
Volker Lanz e55a076615 fix typo
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1100688
2010-03-08 10:27:05 +00:00
Volker Lanz fe9ad46a98 add option to specify the minimum log level
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1100568
2010-03-07 21:20:33 +00:00
Volker Lanz 4d6b168474 add a context menu to the log output to allow saving and clearing the log
refactor some code for context menu stuff.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1100535
2010-03-07 19:02:02 +00:00
Volker Lanz 8d71ec34b4 removed no longer used method declartion showPartitionContextMenu
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1100487
2010-03-07 16:54:12 +00:00
Volker Lanz 5aceae05fc negate the THREADED define so threaded device scanning is on by default
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098818
2010-03-04 11:52:37 +00:00
Volker Lanz 899d27fb34 introduce a define to disable threaded device scanning in case we don't find a
workaround for the solid problem.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098456
2010-03-03 18:58:14 +00:00
Volker Lanz 532d84f6e5 move stuff from advanced page to general page
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098326
2010-03-03 13:32:35 +00:00
Volker Lanz 10054c2577 not used anymore
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098316
2010-03-03 13:22:34 +00:00
Volker Lanz 42359826d2 use List face type for config dialog and some icons
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098247
2010-03-03 10:46:23 +00:00
Volker Lanz 55a9af5a8d don't call updatePartitions() any more after pushing operations on the stack,
the push method itself emits a signal that will lead to updateOperations()
being called now.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098237
2010-03-03 10:09:51 +00:00
Volker Lanz 23d78e20b4 just show a "scanning..." msg if there is no device node set
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098233
2010-03-03 09:49:44 +00:00
Volker Lanz 1bc2951102 the progress dialog is set to autoclose so it's not necessary to hide it in the
main window

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098231
2010-03-03 09:48:59 +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 845f44ccef make sure we still have a selected partition when trying to use it (now that
the signal handler for operationsChanged in MainWindow calls updatePartitions,
this is required)

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1098148
2010-03-02 23:56:21 +00:00
Volker Lanz 3392940beb add basic export-partitiontable-feature
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1097939
2010-03-02 13:35:57 +00:00
Volker Lanz afffc3b4d8 don't assume a device always has a partition table.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1097675
2010-03-01 21:13:36 +00:00
Volker Lanz 2e82663ca9 update info pane when creating partition table
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1097656
2010-03-01 20:15:10 +00:00
Volker Lanz 856ef859eb rename msdos_vista to msdos and make sure to use sector-based-alignment instead
of vista. also use cylinder based instead of msdos legacy.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1097441
2010-03-01 12:00:07 +00:00
Volker Lanz f1ab5d8d7f fix off by one
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1096696
2010-02-27 12:52:00 +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 a8b19642fc rename "snapping" to "aligning" partitions
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1095443
2010-02-24 11:06:32 +00:00
Volker Lanz bd1f7b8c5d allow changing the msdos partition alignment from the device properties
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1095438
2010-02-24 10:47:22 +00:00
Volker Lanz 6dba1bbbd1 remove unused signal
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1095437
2010-02-24 10:45:26 +00:00
Volker Lanz 2eb8c42c1d Remove the few lines related to dbus stuff as long as we're not using any of it
anyway.

Refactor PartitionManagerWidget() and MainWindopw(), moving lots of stuff not
directly related to the PartTableWidget/TreePartition-combo from the former to
the latter. This completely breaks the KCM for now.

Remember the currently selected device across rescans.

Use the partition and device container widget for the context menus of
partitions and devices.

Use QMegatObject::connectSlotByName() where possible, even setting object names
where required to make that work.

Emit operationsChanged() and devicesChanged() in OperationStack because only
that makes any sense.

Add devices properties to toolbar.

Rename itemActivated signal in PartTableWidget to itemDoubleClicked.

DeviceScanner, OperationRunner and OperationStack are child QObjects of
MainWindow now.


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1095086
2010-02-23 16:30:05 +00:00
Volker Lanz 5d278d64b8 make sure not to show our own status bar if we're a kpart
init m_ActionCollection first so isKPart() is guaranteed to work as early as
possible

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1093899
2010-02-21 17:54:52 +00:00
Volker Lanz 4d036f7783 clean up xml gui file and copy changes to kpart's rc file, too
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1093893
2010-02-21 17:38:24 +00:00
Volker Lanz f8a79b009d save and restore dialog sizes for edit mount points and mount options
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1093882
2010-02-21 17:07:47 +00:00
Volker Lanz 9c73e8f052 save and restore size for configure dialog
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1093877
2010-02-21 17:03:22 +00:00
Volker Lanz 241ae7105e add action to hide/show menu bar
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1093874
2010-02-21 16:58:27 +00:00
Volker Lanz baa03c4d78 don't pass a pointer to the selected device to ListDevice::updateDevices: this
doesn't have any effect anyway.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1092963
2010-02-19 21:25:48 +00:00
Volker Lanz 51f3be7690 don't connect do itemActivated for listDevies, connect to itemDoubleClicked.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1092961
2010-02-19 21:09:14 +00:00
Yuri Chornoivan fb63e4886f typo fix
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1092260
2010-02-18 16:43:04 +00:00
Volker Lanz e8e8796d46 add action for device properties to collection.
add the device properties action to device context menu.

open device properties when double clicking device in tree widget.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091984
2010-02-18 00:06:36 +00:00
Volker Lanz 16861abe7d The available and used colors in the config aren't part of the file system color array.
Actually do use these colors in the part widget.

Improve the look of the selection in the part widget.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091952
2010-02-17 23:00:55 +00:00
Volker Lanz 4849ec5ff8 Add colors to identify each individual type of file system plus a config page
to change these colors.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091881
2010-02-17 19:39:24 +00:00
Volker Lanz 06e7a29038 Add some more columns to the partition tree now that columns can easily be
hidden. Pick a sane set of columns to show by default, too.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091807
2010-02-17 16:11:16 +00:00
Volker Lanz 51faaebb38 Add some basic configuration dialog stuff.
Remove the option to create msdos-vista-compatible partition tables. Instead,
use a global config to determine which alignment to use.

Add a device properties dialog.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091755
2010-02-17 13:18:25 +00:00
Volker Lanz 1f3ed68b34 add read-only flag to PartTableWidget
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091653
2010-02-17 10:06:23 +00:00
Volker Lanz 26365e1079 allow turning on and off columns in the partition tree; save and restore the
settings in the config

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1091219
2010-02-16 20:07:33 +00:00
Volker Lanz f8b36e35b5 move the code to detect if we're a KPart to its own method
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1089609
2010-02-13 14:21:05 +00:00
Volker Lanz d0a66f66e1 use the modal window attribute to disable the main window while a progress
dialog is running instead of the hackish way we did that

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1089565
2010-02-13 12:31:29 +00:00
Volker Lanz d9fd184c9d Add some basic read-write-locking to the previewDevices.
Remove comment about race conditions when setting the selected device. Turns
out this wasn't at all the case. It was a signal loop, instead.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1089499
2010-02-13 11:25:56 +00:00
Volker Lanz 8ee33739c6 use previewDevices(), not the property itself, in OperationStack
use operationStack().previewDevices() where possible in the pm widget

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1089122
2010-02-12 13:30:28 +00:00
Volker Lanz eca8342e75 Clean up ListOperations.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1089102
2010-02-12 11:49:35 +00:00
Volker Lanz 7991de7fef Clean up ListDevices and, in the process, also MainWindow and the KCM.
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1089088
2010-02-12 11:29:12 +00:00
Volker Lanz 921d6b18e6 add some config values for advanced stuff:
- allow applying operations for non-root users if
  "allowApplyOperationsForNonRoot" is set to true (default is false)

- hide the radio button to create vista msdos partition tables unless
  "allowCreateVistaPartitionTable" is true (default is false). The reason for
  this is that there are, of course, no "vista msdos partition tables" in
  reality, it's just a Microsoft stupidity that only works as long as there is
  actually a partition starting at sector 2048 in that partition table. If the
  partition table is just created empty, we have no way to determine it was
  meant to be a "vista msdos partition table".

- allow settings the sector alignment for msdos-vista partition tables (default
  is 2048, just like vista).


svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1088920
2010-02-11 22:26:51 +00:00
Volker Lanz bead785279 don't include headers no longer needed
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1088860
2010-02-11 20:11:57 +00:00
Volker Lanz 6f5680866c Add a DeviceScanner class. Move code to scan for devices from
core/libparted.cpp to this new class and use this class in
PartitionManagerWidget

Move the libparted-specific code to inspect _one_ device to a static method in
LibParted.

Make scanning for devices asynchronous with the new DeviceScanner class.

Introduce a progress dialog to show progress while scanning.

Rename the progress dialog for applying operations to something less generic.

Remove the signal emitted when the status bar should change: It's the same
logic used for the signal emitted when operations change.

Remove the onFinished() method in PartitionManagerWidget and directly connect
the finished signal from the apply-progress-dialog to the scanDevices slot.

Rename the PartitionManagerWidget::selectionChanged() signal to the less generic
PartitionManagerWidget::selectedPartitionChanged().

Rename PartitionManagerWidget::clearSelection() to the less generic
PartitionManagerWidget::clearSelectedPartition().

NOTE: The DeviceScanner class is a thread and exposes some race conditions if
not used with caution (aka workarounds). See comments in
PartitionManagerWidget::onScanDevicesFinished().

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1088844
2010-02-11 18:47:51 +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 058f79debd emit devicesChanged() on undo: the disk label type might change
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1083488
2010-02-01 10:40:28 +00:00
Yuri Chornoivan fe08f80bb6 typo: partitin->partition
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1082238
2010-01-30 07:03:57 +00:00
Volker Lanz 40a8e43747 make sure the info pane shows the new partition table type name
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1081932
2010-01-29 11:35:07 +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 275dfde876 revert r1077006: don't show all devices in partition tree. it's just too
confusing.

but do keep the code to show the first device by default. also add code to make
sure the devices list shows the selected devices as indeed selected in the list
widget.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1081532
2010-01-28 16:43:27 +00:00
Volker Lanz 16dae55d04 revert 1077129: re-add devices list. this is just not usable with >4 devices
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1081529
2010-01-28 16:27: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 8b6f51e0f1 add minimal dbus support
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1080818
2010-01-27 00:28:43 +00:00
Volker Lanz a6427ee3ce rename log class to Log to avoid clashes with the C math lib function of the
same name

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1080742
2010-01-26 21:12:42 +00:00
Volker Lanz 4f5253e6a2 remove devices list
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1077129
2010-01-19 12:56:27 +00:00
Volker Lanz f67ca33866 move setSelectedDevice method to a more suitable position in the file
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1077016
2010-01-19 10:34:53 +00:00
Volker Lanz c98b1d702b yet another fix for info pane layout
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1077012
2010-01-19 10:31:42 +00:00
Volker Lanz e16357d14b show all devices in the tree widget
show the first device per default

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1077006
2010-01-19 10:23:20 +00:00
Volker Lanz 90720ad383 hard code some size hint into the file system support dialog so it doesn't open
way too small on first time. also, add some const accessors to the class while
we're at it.

svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1076607
2010-01-18 13:46:45 +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 d975416a53 allow removing a mount point by clearing its mount path
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1075868
2010-01-16 22:31:39 +00:00
Volker Lanz 57f900812a no else required here
svn path=/trunk/extragear/sysadmin/partitionmanager/; revision=1075864
2010-01-16 22:28:52 +00:00