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

List:       kde-commits
Subject:    branches/KDE/3.5/kdesdk/umbrello/umbrello
From:       Oliver Kellogg <okellogg () users ! sourceforge ! net>
Date:       2005-08-02 20:09:57
Message-ID: 1123013397.009207.30297.nullmailer () svn ! kde ! org
[Download RAW message or body]

SVN commit 442484 by okellogg:

slotCurrentViewChanged(): Prevent error messages about "no such signal
 QObject::sigShowGridToggled()" or "... sigSnapToGridToggled".
Still this code need more reworking.


 M  +6 -3      uml.cpp  


--- branches/KDE/3.5/kdesdk/umbrello/umbrello/uml.cpp #442483:442484
@@ -1426,10 +1426,13 @@
 }
 
 void UMLApp::slotCurrentViewChanged() {
-    if ( m_doc->getCurrentView() ) {
-        connect(m_doc->getCurrentView(), SIGNAL( sigShowGridToggled(bool) ),
+    UMLView *viewAtDoc = m_doc->getCurrentView();
+    // FIXME: This whole business of UMLDoc::getCurrentView() vs.
+    //        UMLApp::getCurrentView() is a shame.
+    if (viewAtDoc) {
+        connect(viewAtDoc, SIGNAL( sigShowGridToggled(bool) ),
                 this, SLOT( slotShowGridToggled(bool) ) );
-        connect(m_doc->getCurrentView(), SIGNAL( sigSnapToGridToggled(bool) ),
+        connect(viewAtDoc, SIGNAL( sigSnapToGridToggled(bool) ),
                 this, SLOT( slotSnapToGridToggled(bool) ) );
     }
 }
[prev in list] [next in list] [prev in thread] [next in thread] 

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