Kaydet (Commit) f4003ccb authored tarafından Jan Holesovsky's avatar Jan Holesovsky

personas: Better default searches, improved error messaging.

Change-Id: I0a1303f5864516efbf69e7a0227f17e43aea4af7
üst 8288aaa5
...@@ -45,23 +45,23 @@ SelectPersonaDialog::SelectPersonaDialog( Window *pParent ) ...@@ -45,23 +45,23 @@ SelectPersonaDialog::SelectPersonaDialog( Window *pParent )
m_pSearchButton->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) ); m_pSearchButton->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) );
get( m_vSearchSuggestions[0], "suggestion1" ); get( m_vSearchSuggestions[0], "suggestion1" );
m_vSearchSuggestions[0]->SetText( "libreoffice" ); m_vSearchSuggestions[0]->SetText( "LibreOffice" );
m_vSearchSuggestions[0]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) ); m_vSearchSuggestions[0]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) );
get( m_vSearchSuggestions[1], "suggestion2" ); get( m_vSearchSuggestions[1], "suggestion2" );
m_vSearchSuggestions[1]->SetText( "science" ); m_vSearchSuggestions[1]->SetText( "Abstract" );
m_vSearchSuggestions[1]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) ); m_vSearchSuggestions[1]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) );
get( m_vSearchSuggestions[2], "suggestion3" ); get( m_vSearchSuggestions[2], "suggestion3" );
m_vSearchSuggestions[2]->SetText( "firefox" ); m_vSearchSuggestions[2]->SetText( "Color" );
m_vSearchSuggestions[2]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) ); m_vSearchSuggestions[2]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) );
get( m_vSearchSuggestions[3], "suggestion4" ); get( m_vSearchSuggestions[3], "suggestion4" );
m_vSearchSuggestions[3]->SetText( "nasa" ); m_vSearchSuggestions[3]->SetText( "Music" );
m_vSearchSuggestions[3]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) ); m_vSearchSuggestions[3]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) );
get( m_vSearchSuggestions[4], "suggestion5" ); get( m_vSearchSuggestions[4], "suggestion5" );
m_vSearchSuggestions[4]->SetText( "harry potter" ); m_vSearchSuggestions[4]->SetText( "Nature" );
m_vSearchSuggestions[4]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) ); m_vSearchSuggestions[4]->SetClickHdl( LINK( this, SelectPersonaDialog, SearchPersonas ) );
get( m_pEdit, "search_term" ); get( m_pEdit, "search_term" );
...@@ -562,8 +562,9 @@ void SearchAndParseThread::execute() ...@@ -562,8 +562,9 @@ void SearchAndParseThread::execute()
} }
catch (...) catch (...)
{ {
sProgress = CUI_RES( RID_SVXSTR_SEARCHERROR ); sProgress = CUI_RES(RID_SVXSTR_SEARCHERROR);
m_pPersonaDialog->SetProgress( sProgress ); sProgress = sProgress.replaceAll("%1", m_aURL);
m_pPersonaDialog->SetProgress(sProgress);
return; return;
} }
......
...@@ -31,12 +31,12 @@ String RID_SVXSTR_SELECTEDPERSONA ...@@ -31,12 +31,12 @@ String RID_SVXSTR_SELECTEDPERSONA
String RID_SVXSTR_SEARCHING String RID_SVXSTR_SEARCHING
{ {
Text [ en-US ] = "Searching.. Please Wait.."; Text [ en-US ] = "Searching, please wait...";
}; };
String RID_SVXSTR_SEARCHERROR String RID_SVXSTR_SEARCHERROR
{ {
Text [ en-US ] = "Something went wrong. Please try again."; Text [ en-US ] = "Cannot open %1, please try again later.";
}; };
String RID_SVXSTR_NORESULTS String RID_SVXSTR_NORESULTS
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment