Bug 126475 - Gwenview should start in the directory it was closed in last time
Summary: Gwenview should start in the directory it was closed in last time
Status: RESOLVED FIXED
Alias: None
Product: gwenview
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: unspecified Linux
: NOR wishlist
Target Milestone: ---
Assignee: Gwenview Bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-04-29 17:49 UTC by Philipp Sternberg
Modified: 2012-10-19 13:26 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 Philipp Sternberg 2006-04-29 17:49:11 UTC
Version:           1.3.1 (using KDE 3.5.1, Debian Package 4:3.5.1-2 (testing/unstable))
Compiler:          Target: i486-linux-gnu
OS:                Linux (i686) release 2.6.14.2y

Hi

like Gwenview very much esp. as it is very very usable. In terms of usability it would be nice if Gwenview would start in the directory in which it was closed the last time.

Ok, i'm not asking for making this standard behaviour, this may be annoying for useres how are used to see Gwenview starting in their home-directory. However it would be nice if this could be implemnted as an option (preferably configurable in the Misc. section of the configuration dialog or in a new section called "Startup")...

Regards

Philipp
Comment 1 Aurelien Gateau 2006-08-17 00:34:16 UTC
SVN commit 573656 by gateau:

Optionally remember last URL.
BUG: 126475


 M  +2 -0      NEWS  
 M  +28 -0     app/configrememberpage.ui  
 M  +7 -1      app/main.cpp  
 M  +4 -0      gvcore/rememberconfig.kcfg  


--- trunk/extragear/graphics/gwenview/NEWS #573655:573656
@@ -2,6 +2,8 @@
 - New features:
  - Use the same delete dialog as Amarok and Juk, to easily choose between
    sending files to trash or permanently deleting them.
+ - A page has been added to let the user select which settings should be
+   remembered when Gwenview is restarted.
 - Fixes:
  - The thumbnail files are now generated using correct name and permissions
    according to Thumbnail Managing Standard
--- trunk/extragear/graphics/gwenview/app/configrememberpage.ui #573655:573656
@@ -29,7 +29,35 @@
             <property name="text">
                 <string>State of filter</string>
             </property>
+            <property name="accel">
+                <string></string>
+            </property>
         </widget>
+        <widget class="QCheckBox">
+            <property name="name">
+                <cstring>kcfg_url</cstring>
+            </property>
+            <property name="text">
+                <string>Last opened URL</string>
+            </property>
+        </widget>
+        <spacer>
+            <property name="name">
+                <cstring>spacer1</cstring>
+            </property>
+            <property name="orientation">
+                <enum>Vertical</enum>
+            </property>
+            <property name="sizeType">
+                <enum>Expanding</enum>
+            </property>
+            <property name="sizeHint">
+                <size>
+                    <width>33</width>
+                    <height>104</height>
+                </size>
+            </property>
+        </spacer>
     </vbox>
 </widget>
 <layoutdefaults spacing="6" margin="11"/>
--- trunk/extragear/graphics/gwenview/app/main.cpp #573655:573656
@@ -29,6 +29,8 @@
 #include "gvcore/cache.h"
 #include "gvcore/fileviewcontroller.h"
 #include <../gvcore/fileviewconfig.h>
+#include <../gvcore/miscconfig.h>
+#include <../gvcore/rememberconfig.h>
 #include "mainwindow.h"
 namespace Gwenview {
 
@@ -145,7 +147,11 @@
 		if (args->count()>0) {
 			url=args->url(0);
 		} else {
-			url.setPath( QDir::currentDirPath() );
+			if (RememberConfig::url() && MiscConfig::history().count() > 0) {
+				url = KURL(MiscConfig::history()[0]);
+			} else {
+				url.setPath( QDir::currentDirPath() );
+			}
 		}
 		mainWindow->openURL(url);
 		
--- trunk/extragear/graphics/gwenview/gvcore/rememberconfig.kcfg #573655:573656
@@ -7,5 +7,9 @@
       <label>Whether Gwenview should remember the file filter.</label> 
       <default>false</default>
     </entry> 
+    <entry name="url" type="Bool"> 
+      <label>Whether Gwenview should remember the last URL.</label> 
+      <default>false</default>
+    </entry> 
   </group> 
 </kcfg>