accessibilityoptions.cxx (5900e8ec) | accessibilityoptions.cxx (ca6f8f21) |
---|---|
1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 72 unchanged lines hidden (view full) --- 81 sal_Bool GetIsForPagePreviews() const; 82 sal_Bool GetIsHelpTipsDisappear() const; 83 sal_Bool GetIsAllowAnimatedGraphics() const; 84 sal_Bool GetIsAllowAnimatedText() const; 85 sal_Bool GetIsAutomaticFontColor() const; 86 sal_Bool GetIsSystemFont() const; 87 sal_Int16 GetHelpTipSeconds() const; 88 sal_Bool IsSelectionInReadonly() const; | 1/************************************************************** 2 * 3 * Licensed to the Apache Software Foundation (ASF) under one 4 * or more contributor license agreements. See the NOTICE file 5 * distributed with this work for additional information 6 * regarding copyright ownership. The ASF licenses this file 7 * to you under the Apache License, Version 2.0 (the 8 * "License"); you may not use this file except in compliance --- 72 unchanged lines hidden (view full) --- 81 sal_Bool GetIsForPagePreviews() const; 82 sal_Bool GetIsHelpTipsDisappear() const; 83 sal_Bool GetIsAllowAnimatedGraphics() const; 84 sal_Bool GetIsAllowAnimatedText() const; 85 sal_Bool GetIsAutomaticFontColor() const; 86 sal_Bool GetIsSystemFont() const; 87 sal_Int16 GetHelpTipSeconds() const; 88 sal_Bool IsSelectionInReadonly() const; |
89 sal_Int16 GetColorValueSetMaximumRowCount() const; 90 sal_Int16 GetColorValueSetEntryEdgeLength() const; 91 sal_Int16 GetColorValueSetColumnCount() const; 92 sal_Int16 GetEdgeBlending() const; |
|
89 90 void SetAutoDetectSystemHC(sal_Bool bSet); 91 void SetIsForPagePreviews(sal_Bool bSet); 92 void SetIsHelpTipsDisappear(sal_Bool bSet); 93 void SetIsAllowAnimatedGraphics(sal_Bool bSet); 94 void SetIsAllowAnimatedText(sal_Bool bSet); 95 void SetIsAutomaticFontColor(sal_Bool bSet); 96 void SetIsSystemFont(sal_Bool bSet); 97 void SetHelpTipSeconds(sal_Int16 nSet); 98 void SetSelectionInReadonly(sal_Bool bSet); | 93 94 void SetAutoDetectSystemHC(sal_Bool bSet); 95 void SetIsForPagePreviews(sal_Bool bSet); 96 void SetIsHelpTipsDisappear(sal_Bool bSet); 97 void SetIsAllowAnimatedGraphics(sal_Bool bSet); 98 void SetIsAllowAnimatedText(sal_Bool bSet); 99 void SetIsAutomaticFontColor(sal_Bool bSet); 100 void SetIsSystemFont(sal_Bool bSet); 101 void SetHelpTipSeconds(sal_Int16 nSet); 102 void SetSelectionInReadonly(sal_Bool bSet); |
103 void SetColorValueSetMaximumRowCount(sal_Int16 nSet); 104 void SetColorValueSetEntryEdgeLength(sal_Int16 nSet); 105 void SetColorValueSetColumnCount(sal_Int16 nSet); 106 void SetEdgeBlending(sal_Int16 nSet); |
|
99 100 sal_Bool IsModified() const { return bIsModified; }; 101}; 102 103// initialization of static members -------------------------------------- 104 105SvtAccessibilityOptions_Impl* volatile SvtAccessibilityOptions::sm_pSingleImplConfig =NULL; 106sal_Int32 volatile SvtAccessibilityOptions::sm_nAccessibilityRefCount(0); --- 188 unchanged lines hidden (view full) --- 295 catch(const css::uno::Exception& ex) 296 { 297 LogHelper::logIt(ex); 298 } 299 300 return bRet; 301} 302 | 107 108 sal_Bool IsModified() const { return bIsModified; }; 109}; 110 111// initialization of static members -------------------------------------- 112 113SvtAccessibilityOptions_Impl* volatile SvtAccessibilityOptions::sm_pSingleImplConfig =NULL; 114sal_Int32 volatile SvtAccessibilityOptions::sm_nAccessibilityRefCount(0); --- 188 unchanged lines hidden (view full) --- 303 catch(const css::uno::Exception& ex) 304 { 305 LogHelper::logIt(ex); 306 } 307 308 return bRet; 309} 310 |
311sal_Int16 SvtAccessibilityOptions_Impl::GetColorValueSetMaximumRowCount() const 312{ 313 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 314 sal_Int16 nRet = 40; 315 316 try 317 { 318 if(xNode.is()) 319 xNode->getPropertyValue(s_sColorValueSetMaximumRowCount) >>= nRet; 320 } 321 catch(const css::uno::Exception& ex) 322 { 323 LogHelper::logIt(ex); 324 } 325 326 return nRet; 327} 328 329sal_Int16 SvtAccessibilityOptions_Impl::GetColorValueSetEntryEdgeLength() const 330{ 331 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 332 sal_Int16 nRet = 14; 333 334 try 335 { 336 if(xNode.is()) 337 xNode->getPropertyValue(s_sColorValueSetEntryEdgeLength) >>= nRet; 338 } 339 catch(const css::uno::Exception& ex) 340 { 341 LogHelper::logIt(ex); 342 } 343 344 return nRet; 345} 346 347sal_Int16 SvtAccessibilityOptions_Impl::GetColorValueSetColumnCount() const 348{ 349 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 350 sal_Int16 nRet = 12; 351 352 try 353 { 354 if(xNode.is()) 355 xNode->getPropertyValue(s_sColorValueSetColumnCount) >>= nRet; 356 } 357 catch(const css::uno::Exception& ex) 358 { 359 LogHelper::logIt(ex); 360 } 361 362 return nRet; 363} 364 365sal_Int16 SvtAccessibilityOptions_Impl::GetEdgeBlending() const 366{ 367 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 368 sal_Int16 nRet = 35; 369 370 try 371 { 372 if(xNode.is()) 373 xNode->getPropertyValue(s_sEdgeBlending) >>= nRet; 374 } 375 catch(const css::uno::Exception& ex) 376 { 377 LogHelper::logIt(ex); 378 } 379 380 return nRet; 381} 382 |
|
303void SvtAccessibilityOptions_Impl::SetAutoDetectSystemHC(sal_Bool bSet) 304{ 305 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 306 307 try 308 { 309 if(xNode.is() && xNode->getPropertyValue(s_sAutoDetectSystemHC)!=bSet) 310 { --- 181 unchanged lines hidden (view full) --- 492 aStyleSettings.SetUseSystemUIFonts( GetIsSystemFont() ); 493 aAllSettings.SetStyleSettings(aStyleSettings); 494 Application::MergeSystemSettings( aAllSettings ); 495 } 496 497 Application::SetSettings(aAllSettings); 498} 499 | 383void SvtAccessibilityOptions_Impl::SetAutoDetectSystemHC(sal_Bool bSet) 384{ 385 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 386 387 try 388 { 389 if(xNode.is() && xNode->getPropertyValue(s_sAutoDetectSystemHC)!=bSet) 390 { --- 181 unchanged lines hidden (view full) --- 572 aStyleSettings.SetUseSystemUIFonts( GetIsSystemFont() ); 573 aAllSettings.SetStyleSettings(aStyleSettings); 574 Application::MergeSystemSettings( aAllSettings ); 575 } 576 577 Application::SetSettings(aAllSettings); 578} 579 |
580void SvtAccessibilityOptions_Impl::SetColorValueSetMaximumRowCount(sal_Int16 nSet) 581{ 582 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 583 584 try 585 { 586 if(xNode.is() && xNode->getPropertyValue(s_sColorValueSetMaximumRowCount)!=nSet) 587 { 588 xNode->setPropertyValue(s_sColorValueSetMaximumRowCount, css::uno::makeAny(nSet)); 589 ::comphelper::ConfigurationHelper::flush(m_xCfg); 590 591 bIsModified = sal_True; 592 } 593 } 594 catch(const css::uno::Exception& ex) 595 { 596 LogHelper::logIt(ex); 597 } 598} 599 600void SvtAccessibilityOptions_Impl::SetColorValueSetEntryEdgeLength(sal_Int16 nSet) 601{ 602 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 603 604 try 605 { 606 if(xNode.is() && xNode->getPropertyValue(s_sColorValueSetEntryEdgeLength)!=nSet) 607 { 608 xNode->setPropertyValue(s_sColorValueSetEntryEdgeLength, css::uno::makeAny(nSet)); 609 ::comphelper::ConfigurationHelper::flush(m_xCfg); 610 611 bIsModified = sal_True; 612 } 613 } 614 catch(const css::uno::Exception& ex) 615 { 616 LogHelper::logIt(ex); 617 } 618} 619 620void SvtAccessibilityOptions_Impl::SetColorValueSetColumnCount(sal_Int16 nSet) 621{ 622 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 623 624 try 625 { 626 if(xNode.is() && xNode->getPropertyValue(s_sColorValueSetColumnCount)!=nSet) 627 { 628 xNode->setPropertyValue(s_sColorValueSetColumnCount, css::uno::makeAny(nSet)); 629 ::comphelper::ConfigurationHelper::flush(m_xCfg); 630 631 bIsModified = sal_True; 632 } 633 } 634 catch(const css::uno::Exception& ex) 635 { 636 LogHelper::logIt(ex); 637 } 638} 639 640void SvtAccessibilityOptions_Impl::SetEdgeBlending(sal_Int16 nSet) 641{ 642 css::uno::Reference< css::beans::XPropertySet > xNode(m_xCfg, css::uno::UNO_QUERY); 643 644 try 645 { 646 if(xNode.is() && xNode->getPropertyValue(s_sEdgeBlending)!=nSet) 647 { 648 xNode->setPropertyValue(s_sEdgeBlending, css::uno::makeAny(nSet)); 649 ::comphelper::ConfigurationHelper::flush(m_xCfg); 650 651 bIsModified = sal_True; 652 } 653 } 654 catch(const css::uno::Exception& ex) 655 { 656 LogHelper::logIt(ex); 657 } 658} 659 |
|
500// ----------------------------------------------------------------------- 501// class SvtAccessibilityOptions -------------------------------------------------- 502 503SvtAccessibilityOptions::SvtAccessibilityOptions() 504{ 505 { 506 ::osl::MutexGuard aGuard( SingletonMutex::get() ); 507 if(!sm_pSingleImplConfig) --- 87 unchanged lines hidden (view full) --- 595{ 596 return sm_pSingleImplConfig->GetHelpTipSeconds(); 597} 598sal_Bool SvtAccessibilityOptions::IsSelectionInReadonly() const 599{ 600 return sm_pSingleImplConfig->IsSelectionInReadonly(); 601} 602 | 660// ----------------------------------------------------------------------- 661// class SvtAccessibilityOptions -------------------------------------------------- 662 663SvtAccessibilityOptions::SvtAccessibilityOptions() 664{ 665 { 666 ::osl::MutexGuard aGuard( SingletonMutex::get() ); 667 if(!sm_pSingleImplConfig) --- 87 unchanged lines hidden (view full) --- 755{ 756 return sm_pSingleImplConfig->GetHelpTipSeconds(); 757} 758sal_Bool SvtAccessibilityOptions::IsSelectionInReadonly() const 759{ 760 return sm_pSingleImplConfig->IsSelectionInReadonly(); 761} 762 |
763sal_Int16 SvtAccessibilityOptions::GetColorValueSetMaximumRowCount() const 764{ 765 return sm_pSingleImplConfig->GetColorValueSetMaximumRowCount(); 766} 767 768sal_Int16 SvtAccessibilityOptions::GetColorValueSetEntryEdgeLength() const 769{ 770 return sm_pSingleImplConfig->GetColorValueSetEntryEdgeLength(); 771} 772 773sal_Int16 SvtAccessibilityOptions::GetColorValueSetColumnCount() const 774{ 775 return sm_pSingleImplConfig->GetColorValueSetColumnCount(); 776} 777 778sal_Int16 SvtAccessibilityOptions::GetEdgeBlending() const 779{ 780 return sm_pSingleImplConfig->GetEdgeBlending(); 781} 782 |
|
603// ----------------------------------------------------------------------- 604void SvtAccessibilityOptions::SetAutoDetectSystemHC(sal_Bool bSet) 605{ 606 sm_pSingleImplConfig->SetAutoDetectSystemHC(bSet); 607} 608void SvtAccessibilityOptions::SetIsForPagePreviews(sal_Bool bSet) 609{ 610 sm_pSingleImplConfig->SetIsForPagePreviews(bSet); --- 21 unchanged lines hidden (view full) --- 632void SvtAccessibilityOptions::SetHelpTipSeconds(sal_Int16 nSet) 633{ 634 sm_pSingleImplConfig->SetHelpTipSeconds(nSet); 635} 636void SvtAccessibilityOptions::SetSelectionInReadonly(sal_Bool bSet) 637{ 638 sm_pSingleImplConfig->SetSelectionInReadonly(bSet); 639} | 783// ----------------------------------------------------------------------- 784void SvtAccessibilityOptions::SetAutoDetectSystemHC(sal_Bool bSet) 785{ 786 sm_pSingleImplConfig->SetAutoDetectSystemHC(bSet); 787} 788void SvtAccessibilityOptions::SetIsForPagePreviews(sal_Bool bSet) 789{ 790 sm_pSingleImplConfig->SetIsForPagePreviews(bSet); --- 21 unchanged lines hidden (view full) --- 812void SvtAccessibilityOptions::SetHelpTipSeconds(sal_Int16 nSet) 813{ 814 sm_pSingleImplConfig->SetHelpTipSeconds(nSet); 815} 816void SvtAccessibilityOptions::SetSelectionInReadonly(sal_Bool bSet) 817{ 818 sm_pSingleImplConfig->SetSelectionInReadonly(bSet); 819} |
640 | |
641void SvtAccessibilityOptions::SetVCLSettings() 642{ 643 sm_pSingleImplConfig->SetVCLSettings(); 644} | 820void SvtAccessibilityOptions::SetVCLSettings() 821{ 822 sm_pSingleImplConfig->SetVCLSettings(); 823} |
824void SvtAccessibilityOptions::SetColorValueSetMaximumRowCount(sal_Int16 nSet) 825{ 826 sm_pSingleImplConfig->SetColorValueSetMaximumRowCount(nSet); 827} 828void SvtAccessibilityOptions::SetColorValueSetEntryEdgeLength(sal_Int16 nSet) 829{ 830 sm_pSingleImplConfig->SetColorValueSetEntryEdgeLength(nSet); 831} 832void SvtAccessibilityOptions::SetColorValueSetColumnCount(sal_Int16 nSet) 833{ 834 sm_pSingleImplConfig->SetColorValueSetColumnCount(nSet); 835} 836void SvtAccessibilityOptions::SetEdgeBlending(sal_Int16 nSet) 837{ 838 sm_pSingleImplConfig->SetEdgeBlending(nSet); 839} |
|
645// ----------------------------------------------------------------------- | 840// ----------------------------------------------------------------------- |