[prev in list] [next in list] [prev in thread] [next in thread] 

List:       ktexteditor-devel
Subject:    Change SelectionMode on kate filebrowser plugin
From:       Massimo Fidanza <max () massimofidanza ! it>
Date:       2007-02-18 23:01:09
Message-ID: 45D8DAB5.9000506 () massimofidanza ! it
[Download RAW message or body]

Hi,

I discussed this with sredna an he is in agreement with me to change 
SelectionMode from KFile::Multi to KFile::Extended.
As I use Kde double click mode, I have problems if SelectionMode is set 
to KFile::Multi, because files remains selected when I click once on 
them. For example if I select 3 files and double click on one of them 
the one I double click on is unselected and not opened, but instead the 
other 2 get opened. Set SelectionMode to KFile::Extended solve the 
problem, now multi selection can be made with CTRL + LEFT MOUSE and then 
all files can be opened with RETURN key. I think that I can try to open 
them also with the mouse, what do you think?
The patch is attached.

Massimo

["filebrowser.diff" (text/plain)]

Index: katefileselector.cpp
===================================================================
--- katefileselector.cpp	(revisione 634933)
+++ katefileselector.cpp	(copia locale)
@@ -203,7 +203,7 @@
 
   dir = new KDirOperator(KUrl(), this);
   dir->setView(KFile::/* Simple */Detail);
-  dir->view()->setSelectionMode(KFile::Multi);
+  dir->view()->setSelectionMode(KFile::Extended);
   setStretchFactor(dir, 2);
   dir->setSizePolicy (QSizePolicy (QSizePolicy::MinimumExpanding, QSizePolicy::MinimumExpanding));
 
@@ -297,7 +297,7 @@
   KConfigGroup confDirGroup(config, name + ":dir");
   dir->readConfig(&confDirGroup);
   dir->setView( KFile::Default );
-  dir->view()->setSelectionMode(KFile::Multi);
+  dir->view()->setSelectionMode(KFile::Extended);
   config->setGroup( name );
 
   // set up the toolbar
@@ -384,7 +384,7 @@
 void ::KateFileSelector::setView(KFile::FileView view)
 {
   dir->setView(view);
-  dir->view()->setSelectionMode(KFile::Multi);
+  dir->view()->setSelectionMode(KFile::Extended);
 }
 
 //END Public Methods


_______________________________________________
KTextEditor-Devel mailing list
KTextEditor-Devel@kde.org
https://mail.kde.org/mailman/listinfo/ktexteditor-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic