Diffstat (limited to 'noncore/apps/advancedfm/advancedfm.cpp') (more/less context) (show whitespace changes)
-rw-r--r-- | noncore/apps/advancedfm/advancedfm.cpp | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/noncore/apps/advancedfm/advancedfm.cpp b/noncore/apps/advancedfm/advancedfm.cpp index c653b90..9edf7c1 100644 --- a/noncore/apps/advancedfm/advancedfm.cpp +++ b/noncore/apps/advancedfm/advancedfm.cpp | |||
@@ -64,12 +64,14 @@ | |||
64 | #include <mntent.h> | 64 | #include <mntent.h> |
65 | #include <sys/utsname.h> | 65 | #include <sys/utsname.h> |
66 | 66 | ||
67 | AdvancedFm::AdvancedFm( ) | 67 | AdvancedFm::AdvancedFm( ) |
68 | : QMainWindow( ) { | 68 | : QMainWindow( ) { |
69 | init(); | 69 | init(); |
70 | renameBox = 0; | ||
71 | |||
70 | initConnections(); | 72 | initConnections(); |
71 | populateLocalView(); | 73 | populateLocalView(); |
72 | populateRemoteView(); | 74 | populateRemoteView(); |
73 | currentPathCombo->setFocus(); | 75 | currentPathCombo->setFocus(); |
74 | } | 76 | } |
75 | 77 | ||
@@ -399,24 +401,39 @@ void AdvancedFm::remoteListClicked(QListViewItem *selectedItem) { | |||
399 | 401 | ||
400 | 402 | ||
401 | void AdvancedFm::localListPressed( int mouse, QListViewItem *, const QPoint& , int ) { | 403 | void AdvancedFm::localListPressed( int mouse, QListViewItem *, const QPoint& , int ) { |
402 | // qDebug("list pressed"); | 404 | // qDebug("list pressed"); |
403 | switch (mouse) { | 405 | switch (mouse) { |
404 | case 1: | 406 | case 1: |
407 | { | ||
408 | if(renameBox != 0 ) | ||
409 | { | ||
410 | qDebug("cancel rename"); | ||
411 | cancelRename(); | ||
412 | } | ||
413 | |||
414 | } | ||
405 | break; | 415 | break; |
406 | case 2: | 416 | case 2: |
407 | menuTimer.start( 500, TRUE ); | 417 | menuTimer.start( 500, TRUE ); |
408 | qDebug("Start menu timer\n"); | 418 | qDebug("Start menu timer\n"); |
409 | break; | 419 | break; |
410 | }; | 420 | }; |
411 | } | 421 | } |
412 | 422 | ||
413 | void AdvancedFm::remoteListPressed( int mouse, QListViewItem*, const QPoint&, int ) { | 423 | void AdvancedFm::remoteListPressed( int mouse, QListViewItem*, const QPoint&, int ) { |
414 | 424 | ||
415 | switch (mouse) { | 425 | switch (mouse) { |
416 | case 1: | 426 | case 1: |
427 | { | ||
428 | if(renameBox != 0 ) | ||
429 | { | ||
430 | qDebug("cancel rename"); | ||
431 | cancelRename(); | ||
432 | } | ||
433 | } | ||
417 | break; | 434 | break; |
418 | case 2: | 435 | case 2: |
419 | menuTimer.start( 500, TRUE ); | 436 | menuTimer.start( 500, TRUE ); |
420 | qDebug("Start menu timer"); | 437 | qDebug("Start menu timer"); |
421 | break; | 438 | break; |
422 | }; | 439 | }; |
@@ -876,6 +893,7 @@ void AdvancedFm::addToDocs() { | |||
876 | f.setFile( curFile); | 893 | f.setFile( curFile); |
877 | f.writeLink(); | 894 | f.writeLink(); |
878 | } | 895 | } |
879 | } | 896 | } |
880 | } | 897 | } |
881 | } | 898 | } |
899 | |||