diff options
author | Ocke Janssen <oj@openoffice.org> | 2001-10-23 11:30:27 +0000 |
---|---|---|
committer | Ocke Janssen <oj@openoffice.org> | 2001-10-23 11:30:27 +0000 |
commit | c7bdf73b326c09bd4744725843d78c5b3f7805f6 (patch) | |
tree | c3370f1e4e2c52a14ae2888dd0ee1e0e06e04fb4 /dbaccess/source/ui/querydesign/JoinController.cxx | |
parent | 77ae945975aa441a227670a48171988b3746b489 (diff) |
#93566# slot fixes
Diffstat (limited to 'dbaccess/source/ui/querydesign/JoinController.cxx')
-rw-r--r-- | dbaccess/source/ui/querydesign/JoinController.cxx | 27 |
1 files changed, 25 insertions, 2 deletions
diff --git a/dbaccess/source/ui/querydesign/JoinController.cxx b/dbaccess/source/ui/querydesign/JoinController.cxx index b7c52f940014..2b4b5bc42639 100644 --- a/dbaccess/source/ui/querydesign/JoinController.cxx +++ b/dbaccess/source/ui/querydesign/JoinController.cxx @@ -2,9 +2,9 @@ * * $RCSfile: JoinController.cxx,v $ * - * $Revision: 1.16 $ + * $Revision: 1.17 $ * - * last change: $Author: oj $ $Date: 2001-08-27 06:57:23 $ + * last change: $Author: oj $ $Date: 2001-10-23 12:30:24 $ * * The Contents of this file are made available subject to the terms of * either of the following licenses @@ -338,8 +338,26 @@ void OJoinController::Execute(sal_uInt16 _nId) return; break; case ID_BROWSER_EDITDOC: + if(m_bEditable) + { // the state should be changed to not editable + switch (saveModified()) + { + case RET_CANCEL: + // don't change anything here so return + return; + break; + case RET_NO: + reset(); + setModified(sal_False); // and we are not modified yet + break; + default: + break; + } + } m_bEditable = !m_bEditable; getJoinView()->setReadOnly(!m_bEditable); + InvalidateAll(); + return; break; case ID_BROWSER_UNDO: m_aUndoManager.Undo(); @@ -399,6 +417,11 @@ void OJoinController::AddSupportedFeatures() m_aSupportedFeatures[ ::rtl::OUString::createFromAscii(".uno:DB/Close")] = SID_CLOSEDOC; } // ----------------------------------------------------------------------------- +sal_Bool SAL_CALL OJoinController::suspend(sal_Bool bSuspend) throw( RuntimeException ) +{ + return saveModified() != RET_CANCEL; +} +// ----------------------------------------------------------------------------- |