summaryrefslogtreecommitdiff
path: root/cui
diff options
context:
space:
mode:
authorRachit Gupta <rachitgupta1792@gmail.com>2014-06-13 13:42:25 +0530
committerJan Holesovsky <kendy@collabora.com>2014-08-14 19:43:26 +0200
commit961198a67ec2e3cd83f44e9f0235e91355699602 (patch)
tree117a431172766db40d59b040ecc3ce50fc590291 /cui
parent1192e0bd098ed025bf57764cd1b7cb0fe6a8c36a (diff)
Fixed Bug: Multiple searches result in correct theme to be applied.
The vector that stores the persona settings is cleared every time a new search is performed. This results in the correct theme being selected for downloading and applying. Change-Id: I8c0413a117c5a7ed660cd785c292c2fad4abd486
Diffstat (limited to 'cui')
-rw-r--r--cui/source/options/personalization.cxx7
-rw-r--r--cui/source/options/personalization.hxx1
2 files changed, 8 insertions, 0 deletions
diff --git a/cui/source/options/personalization.cxx b/cui/source/options/personalization.cxx
index 5c2f2c3f5f5f..24c52b998458 100644
--- a/cui/source/options/personalization.cxx
+++ b/cui/source/options/personalization.cxx
@@ -179,6 +179,12 @@ void SelectPersonaDialog::AddPersonaSetting( OUString& rPersonaSetting )
m_vPersonaSettings.push_back( rPersonaSetting );
}
+void SelectPersonaDialog::ClearSearchResults()
+{
+ m_vPersonaSettings.clear();
+ m_aSelectedPersona = "";
+}
+
SvxPersonalizationTabPage::SvxPersonalizationTabPage( Window *pParent, const SfxItemSet &rSet )
: SfxTabPage( pParent, "PersonalizationTabPage", "cui/ui/personalization_tab.ui", &rSet )
{
@@ -377,6 +383,7 @@ void SearchAndParseThread::execute()
{
if(m_pPersonaDialog)
{
+ m_pPersonaDialog->ClearSearchResults();
OUString sProgress( "Searching.. Please Wait.." );
m_pPersonaDialog->SetProgress( sProgress );
Reference<XComponentContext> xContext( ::comphelper::getProcessComponentContext() );
diff --git a/cui/source/options/personalization.hxx b/cui/source/options/personalization.hxx
index da2bdb6d3716..0f3cb7e63ee8 100644
--- a/cui/source/options/personalization.hxx
+++ b/cui/source/options/personalization.hxx
@@ -81,6 +81,7 @@ public:
void SetProgress( OUString& );
void SetImages( std::vector<Image>&);
void AddPersonaSetting( OUString& );
+ void ClearSearchResults();
private:
/// Handle the Search button