User: hr      
Date: 06/04/19 06:24:28

Modified:
 /dba/dbaccess/source/ui/relationdesign/
  RelationTableView.cxx

Log:
 INTEGRATION: CWS oj17 (1.20.94); FILE MERGED
 2006/03/10 12:12:57 oj 1.20.94.1: #129492# clear undo actions when a table was 
removed

File Changes:

Directory: /dba/dbaccess/source/ui/relationdesign/
==================================================

File [changed]: RelationTableView.cxx
Url: 
http://dba.openoffice.org/source/browse/dba/dbaccess/source/ui/relationdesign/RelationTableView.cxx?r1=1.20&r2=1.21
Delta lines:  +10 -1
--------------------
--- RelationTableView.cxx       23 Sep 2005 12:45:21 -0000      1.20
+++ RelationTableView.cxx       19 Apr 2006 13:24:26 -0000      1.21
@@ -122,7 +122,12 @@
 #ifndef DBACCESS_JACCESS_HXX
 #include "JAccess.hxx"
 #endif
+#ifndef _UNDO_HXX
+#include <svtools/undo.hxx>
+#endif
+#ifndef _COM_SUN_STAR_ACCESSIBILITY_ACCESSIBLEEVENTID_HPP_
 #include <com/sun/star/accessibility/AccessibleEventId.hpp>
+#endif
 
 using namespace dbaui;
 using namespace ::dbtools;
@@ -208,7 +213,7 @@
                        ::rtl::OUString strTabExistenceTest = 
pTabConnData->GetSourceWinName();
                        sal_Bool bInvalid = 
::std::find(arrInvalidTables.begin(),arrInvalidTables.end(),strTabExistenceTest)
 != arrInvalidTables.end();
                        strTabExistenceTest = pTabConnData->GetDestWinName();
-                       bInvalid |= 
::std::find(arrInvalidTables.begin(),arrInvalidTables.end(),strTabExistenceTest)
 != arrInvalidTables.end();
+                       bInvalid = bInvalid || 
::std::find(arrInvalidTables.begin(),arrInvalidTables.end(),strTabExistenceTest)
 != arrInvalidTables.end();
 
                        if (bInvalid)
                        {       // nein -> Pech gehabt, die Connection faellt 
weg
@@ -473,8 +478,12 @@
        OSQLMessageBox 
aDlg(this,ModuleRes(STR_QUERY_REL_DELETE_WINDOW),String(),WB_YES_NO|WB_DEF_YES,OSQLMessageBox::Warning);
        if(aDlg.Execute() == RET_YES)
        {
+        m_pView->getController()->getUndoMgr()->Clear();
                OJoinTableView::RemoveTabWin( pTabWin );
+        
                
m_pView->getController()->InvalidateFeature(SID_RELATION_ADD_RELATION);
+        m_pView->getController()->InvalidateFeature(ID_BROWSER_UNDO);
+        m_pView->getController()->InvalidateFeature(ID_BROWSER_REDO);
        }
 }
 // 
-----------------------------------------------------------------------------




---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to