Bug 111176 - cleanup layout (default) shortcut would be nice
Summary: cleanup layout (default) shortcut would be nice
Status: RESOLVED FIXED
Alias: None
Product: kst
Classification: Applications
Component: general (show other bugs)
Version: 1.x
Platform: unspecified Linux
: NOR wishlist
Target Milestone: ---
Assignee: kst
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-08-21 02:48 UTC by Matthew Truch
Modified: 2005-10-20 19:15 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Matthew Truch 2005-08-21 02:48:31 UTC
Version:           1.2.0_devel (using KDE KDE 3.4.0)
OS:                Linux

I often find myself switching to layout mode soley so I can navigate the context menu to cleanup layout -> default.  It would be very nice if there was some kind of shortcut or other way to easily access cleanup layout without having to enter (and then exit) layout mode.
Comment 1 Andrew Walker 2005-10-20 00:58:12 UTC
Is there any reason not to display the Cleanup Layout menu item at all times (i.e. not just in Layout mode)? 

If there are no reasons as to why this is a bad thing to do I'll simply delete two lines of code from ksttoplevelview.cpp.
Comment 2 Netterfield 2005-10-20 06:10:44 UTC
I agree that it would be good to have it everywhere.
Comment 3 Andrew Walker 2005-10-20 19:15:08 UTC
SVN commit 472410 by arwalker:

BUG:111176 Enable the Cleanup Layout menu item in all modes.

 M  +7 -9      ksttoplevelview.cpp  


--- trunk/extragear/graphics/kst/kst/ksttoplevelview.cpp #472409:472410
@@ -1161,16 +1161,14 @@
     rc = true;
   }
 
-  if (_mode == LayoutMode) {
-    if (rc) {
-      menu->insertSeparator();
-    }
-    KPopupMenu *subMenu = new KPopupMenu(menu);
-    subMenu->insertItem(i18n("Default Tile"), this, SLOT(cleanupDefault()));
-    subMenu->insertItem(i18n("Custom..."), this, SLOT(cleanupCustom()));
-    menu->insertItem(i18n("Cleanup Layout"), subMenu);
-    rc = true;
+  if (rc) {
+    menu->insertSeparator();
   }
+  KPopupMenu *subMenu = new KPopupMenu(menu);
+  subMenu->insertItem(i18n("Default Tile"), this, SLOT(cleanupDefault()));
+  subMenu->insertItem(i18n("Custom..."), this, SLOT(cleanupCustom()));
+  menu->insertItem(i18n("Cleanup Layout"), subMenu);
+  rc = true;
 
   // don't release the _pressTarget reference here as we are not yet done with
   //  it, since several of the menu handlers require it in order to function...