diff options
author | Gergo Mocsi <gmocsi91@gmail.com> | 2013-07-23 23:00:55 +0200 |
---|---|---|
committer | Gergo Mocsi <gmocsi91@gmail.com> | 2013-09-02 18:16:48 +0200 |
commit | 70ab744ccf047a90bee0506c6a60ade1935ece3d (patch) | |
tree | 1f84a5f1016decc5f0a9d725020cbcc1bd993115 /basic/source | |
parent | GSOC work, code complete option, menu entry fixes (diff) | |
download | core-70ab744ccf047a90bee0506c6a60ade1935ece3d.tar.gz core-70ab744ccf047a90bee0506c6a60ade1935ece3d.zip |
GSOC work, ModalDialog instead of menu entry
Created a ModalDialog named CodeCompleteOptionsDlg to edit options for code completition/suggestion.
Unimplemented features in it are disabled.
The dialog window uses Glade .ui file.
Change-Id: I1b59f386a9575aa25b38c5a1d7d1f020498a69ab
Diffstat (limited to 'basic/source')
-rw-r--r-- | basic/source/classes/codecompletecache.cxx | 21 | ||||
-rw-r--r-- | basic/source/classes/sbxmod.cxx | 3 |
2 files changed, 16 insertions, 8 deletions
diff --git a/basic/source/classes/codecompletecache.cxx b/basic/source/classes/codecompletecache.cxx index 77a0204eaf30..3898eb2b20ae 100644 --- a/basic/source/classes/codecompletecache.cxx +++ b/basic/source/classes/codecompletecache.cxx @@ -30,24 +30,19 @@ namespace } CodeCompleteOptions::CodeCompleteOptions() -: bIsCodeCompleteOn( false ) +: bIsCodeCompleteOn( false ), +bIsProcedureAutoCompleteOn( false ) { } bool CodeCompleteOptions::IsCodeCompleteOn() { - /*if( !theCodeCompleteOptions::get().aMiscOptions.IsExperimentalMode() ) - return false; - else*/ return theCodeCompleteOptions::get().aMiscOptions.IsExperimentalMode() && theCodeCompleteOptions::get().bIsCodeCompleteOn; } void CodeCompleteOptions::SetCodeCompleteOn( const bool& b ) { - if( !theCodeCompleteOptions::get().aMiscOptions.IsExperimentalMode() ) - theCodeCompleteOptions::get().bIsCodeCompleteOn = false; - else - theCodeCompleteOptions::get().bIsCodeCompleteOn = b; + theCodeCompleteOptions::get().bIsCodeCompleteOn = b; } bool CodeCompleteOptions::IsExtendedTypeDeclaration() @@ -55,6 +50,16 @@ bool CodeCompleteOptions::IsExtendedTypeDeclaration() return CodeCompleteOptions::IsCodeCompleteOn(); } +bool CodeCompleteOptions::IsProcedureAutoCompleteOn() +{ + return theCodeCompleteOptions::get().aMiscOptions.IsExperimentalMode() && theCodeCompleteOptions::get().bIsProcedureAutoCompleteOn; +} + +void CodeCompleteOptions::SetProcedureAutoCompleteOn( const bool& b ) +{ + theCodeCompleteOptions::get().bIsProcedureAutoCompleteOn = b; +} + std::ostream& operator<< (std::ostream& aStream, const CodeCompleteDataCache& aCache) { for( CodeCompleteVarScopes::const_iterator aIt = aCache.aVarScopes.begin(); aIt != aCache.aVarScopes.end(); ++aIt ) diff --git a/basic/source/classes/sbxmod.cxx b/basic/source/classes/sbxmod.cxx index 8182f6e92900..cbe5886640a6 100644 --- a/basic/source/classes/sbxmod.cxx +++ b/basic/source/classes/sbxmod.cxx @@ -671,7 +671,10 @@ void SbModule::EndDefinitions( sal_Bool bNewState ) if( p ) { if( p->bInvalid ) + { + std::cerr << "invalid definition: " << p->GetName() << std::endl; pMethods->Remove( p ); + } else { p->bInvalid = bNewState; |