Fwd: Annoying doubleclicks

David Faure david at mandrakesoft.com
Fri Nov 22 00:24:29 GMT 2002


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

> diff -cr konqueror.old/sidebar/trees/konq_sidebartree.cpp
> konqueror/sidebar/trees/konq_sidebartree.cpp
> *** konqueror.old/sidebar/trees/konq_sidebartree.cpp    2002-11-22
> 00:16:14.000000000 +0100
> --- konqueror/sidebar/trees/konq_sidebartree.cpp        2002-11-22
> 00:32:59.000000000 +0100
> ***************
> *** 104,111 ****
>       m_autoOpenTimer = new QTimer( this );
>       connect( m_autoOpenTimer, SIGNAL( timeout() ),
>                this, SLOT( slotAutoOpenFolder() ) );
> !
> !     connect( this, SIGNAL( doubleClicked( QListViewItem * ) ),
>                this, SLOT( slotDoubleClicked( QListViewItem * ) ) );
>       connect( this, SIGNAL( mouseButtonPressed(int, QListViewItem*, const
> QPoint&, int)),
>                this, SLOT( slotMouseButtonPressed(int, QListViewItem*, const
> QPoint&, int)) );
> --- 104,111 ----
>       m_autoOpenTimer = new QTimer( this );
>       connect( m_autoOpenTimer, SIGNAL( timeout() ),
>                this, SLOT( slotAutoOpenFolder() ) );
> ! //This should always act on signle click, regardless of mousclick mode
> !     connect( this, SIGNAL( clicked( QListViewItem * ) ),
>                this, SLOT( slotDoubleClicked( QListViewItem * ) ) );
>       connect( this, SIGNAL( mouseButtonPressed(int, QListViewItem*, const
> QPoint&, int)),
>                this, SLOT( slotMouseButtonPressed(int, QListViewItem*, const
> QPoint&, int)) );


This sounds correct to me. John - can you explain the reasoning behind
this commit?

- ----------------------------
revision 1.19
date: 2002/07/18 06:05:06;  author: firebaugh;  state: Exp;  lines: +4 -4
Obey single/double click preference.


$ cvs diff -r1.18 -r1.19 konq_sidebartree.cpp
Index: konq_sidebartree.cpp
===================================================================
RCS file: /home/kde/kdebase/konqueror/sidebar/trees/konq_sidebartree.cpp,v
retrieving revision 1.18
retrieving revision 1.19
diff -u -p -r1.18 -r1.19
- --- konq_sidebartree.cpp        2002/02/23 15:17:12     1.18
+++ konq_sidebartree.cpp        2002/07/18 06:05:06     1.19
@@ -108,8 +108,8 @@ KonqSidebarTree::KonqSidebarTree( KonqSi
              this, SLOT( slotDoubleClicked( QListViewItem * ) ) );
     connect( this, SIGNAL( mouseButtonPressed(int, QListViewItem*, const QPoint&, int)),
              this, SLOT( slotMouseButtonPressed(int, QListViewItem*, const QPoint&, int)) );
- -    connect( this, SIGNAL( clicked( QListViewItem * ) ),
- -             this, SLOT( slotClicked( QListViewItem * ) ) );
+    connect( this, SIGNAL( activated( QListViewItem * ) ),
+             this, SLOT( slotExecuted( QListViewItem * ) ) );
     connect( this, SIGNAL( returnPressed( QListViewItem * ) ),
              this, SLOT( slotDoubleClicked( QListViewItem * ) ) );
     connect( this, SIGNAL( selectionChanged() ),
@@ -326,11 +326,11 @@ void KonqSidebarTree::slotDoubleClicked(
     if ( !static_cast<KonqSidebarTreeItem*>(item)->isClickable() )
         return;

- -    slotClicked( item );
+    slotExecuted( item );
     item->setOpen( !item->isOpen() );
 }

- -void KonqSidebarTree::slotClicked( QListViewItem *item )
+void KonqSidebarTree::slotExecuted( QListViewItem *item )
 {
     //kdDebug(1201) << "KonqSidebarTree::slotClicked " << item << endl;
     if ( !item )


Please revert to slotClicked if there is no obvious reason for the above.

- -- 
David FAURE, david at mandrakesoft.com, faure at kde.org
http://people.mandrakesoft.com/~david/
Contributing to: http://www.konqueror.org/, http://www.koffice.org/
Get the latest KOffice - http://download.kde.org/stable/koffice-1.2/
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.7 (GNU/Linux)

iD8DBQE93Xk972KcVAmwbhARArwSAKCgFFNYNA/U9SOI0h4VEhPciLWdUACfd5bN
EXGVVAanagGiOCvUklj5lS4=
=APTI
-----END PGP SIGNATURE-----





More information about the kde-core-devel mailing list