sw/UIConfig_swriter.mk | 1 sw/source/ui/uiview/srcview.cxx | 3 +- sw/source/ui/uiview/view.hrc | 1 sw/source/ui/uiview/view.src | 4 --- sw/source/ui/uiview/viewsrch.cxx | 11 +++------ sw/uiconfig/swriter/ui/infonotfounddialog.ui | 33 +++++++++++++++++++++++++++ 6 files changed, 40 insertions(+), 13 deletions(-)
New commits: commit a96941702a1454afa8ff8f340277cbccb4787a7c Author: Caolán McNamara <caol...@redhat.com> Date: Mon Sep 9 14:31:44 2013 +0100 convert info not found to .ui Change-Id: I553e6f696ad10e847d845c263fbfbab5d2279345 diff --git a/sw/UIConfig_swriter.mk b/sw/UIConfig_swriter.mk index d080e9d..5016644 100644 --- a/sw/UIConfig_swriter.mk +++ b/sw/UIConfig_swriter.mk @@ -117,6 +117,7 @@ $(eval $(call gb_UIConfig_add_uifiles,modules/swriter,\ sw/uiconfig/swriter/ui/indexentry \ sw/uiconfig/swriter/ui/inputfielddialog \ sw/uiconfig/swriter/ui/indentpage \ + sw/uiconfig/swriter/ui/infonotfounddialog \ sw/uiconfig/swriter/ui/inforeadonlydialog \ sw/uiconfig/swriter/ui/insertautotextdialog \ sw/uiconfig/swriter/ui/insertbookmark \ diff --git a/sw/source/ui/uiview/srcview.cxx b/sw/source/ui/uiview/srcview.cxx index c3ceef3..02762d5 100644 --- a/sw/source/ui/uiview/srcview.cxx +++ b/sw/source/ui/uiview/srcview.cxx @@ -631,7 +631,8 @@ sal_uInt16 SwSrcView::StartSearchAndReplace(const SvxSearchItem& rSearchItem, { if(bNotFoundMessage) { - InfoBox( 0, SW_RES(MSG_NOT_FOUND)).Execute(); + MessageDialog(0, "InfoNotFoundDialog", + "modules/swriter/ui/infonotfounddialog.ui").Execute(); } else if(!bRecursive) { diff --git a/sw/source/ui/uiview/view.hrc b/sw/source/ui/uiview/view.hrc index 439f77d..692c45f 100644 --- a/sw/source/ui/uiview/view.hrc +++ b/sw/source/ui/uiview/view.hrc @@ -35,7 +35,6 @@ #define STR_EDIT_FOOTNOTE (RC_VIEW_BEGIN + 14) -#define MSG_NOT_FOUND (RC_VIEW_BEGIN + 16) #define MSG_SEARCH_START (RC_VIEW_BEGIN + 17) #define MSG_SEARCH_END (RC_VIEW_BEGIN + 18) #define STR_NB_REPLACED (RC_VIEW_BEGIN + 20) diff --git a/sw/source/ui/uiview/view.src b/sw/source/ui/uiview/view.src index 1a08b81..23f2f13 100644 --- a/sw/source/ui/uiview/view.src +++ b/sw/source/ui/uiview/view.src @@ -71,10 +71,6 @@ String STR_TEXTOPTIONS { Text [ en-US ] = "Text document"; }; -InfoBox MSG_NOT_FOUND -{ - Message [ en-US ] = "Search key not found." ; -}; InfoBox MSG_SCAN_NOSOURCE { Message [ en-US ] = "Source not specified." ; diff --git a/sw/source/ui/uiview/viewsrch.cxx b/sw/source/ui/uiview/viewsrch.cxx index 2df0a38..6923085 100644 --- a/sw/source/ui/uiview/viewsrch.cxx +++ b/sw/source/ui/uiview/viewsrch.cxx @@ -76,7 +76,7 @@ struct SwSearchOptions SwSearchOptions( SwWrtShell* pSh, sal_Bool bBackward ); }; -inline Window* GetParentWindow( SvxSearchDialog* m_pSrchDlg ) +static Window* GetParentWindow( SvxSearchDialog* m_pSrchDlg ) { Window* pWin; if( m_pSrchDlg && m_pSrchDlg->IsVisible() ) @@ -86,18 +86,15 @@ inline Window* GetParentWindow( SvxSearchDialog* m_pSrchDlg ) return pWin; } -inline void ShowNotFoundInfoBox( SvxSearchDialog* m_pSrchDlg ) +static void ShowNotFoundInfoBox( SvxSearchDialog* m_pSrchDlg ) { Window* pParentWindow = GetParentWindow( m_pSrchDlg ); - InfoBox aBox( pParentWindow, SW_RES(MSG_NOT_FOUND)); + MessageDialog aBox(pParentWindow, "InfoNotFoundDialog", + "modules/swriter/ui/infonotfounddialog.ui"); if (pParentWindow) { aBox.SetText(pParentWindow->GetText()); } - else - { - aBox.SetText(SVX_RESSTR(RID_SVXSTR_FINDBAR_FIND)); - } aBox.Execute(); } diff --git a/sw/uiconfig/swriter/ui/infonotfounddialog.ui b/sw/uiconfig/swriter/ui/infonotfounddialog.ui new file mode 100644 index 0000000..cfb72d2 --- /dev/null +++ b/sw/uiconfig/swriter/ui/infonotfounddialog.ui @@ -0,0 +1,33 @@ +<?xml version="1.0" encoding="UTF-8"?> +<interface> + <!-- interface-requires gtk+ 3.0 --> + <object class="GtkMessageDialog" id="InfoNotFoundDialog"> + <property name="can_focus">False</property> + <property name="border_width">12</property> + <property name="title" translatable="yes">Find</property> + <property name="resizable">False</property> + <property name="type_hint">dialog</property> + <property name="skip_taskbar_hint">True</property> + <property name="buttons">ok</property> + <property name="text" translatable="yes">Search key not found.</property> + <child internal-child="vbox"> + <object class="GtkBox" id="messagedialog-vbox"> + <property name="can_focus">False</property> + <property name="orientation">vertical</property> + <property name="spacing">24</property> + <child internal-child="action_area"> + <object class="GtkButtonBox" id="messagedialog-action_area"> + <property name="can_focus">False</property> + <property name="layout_style">end</property> + </object> + <packing> + <property name="expand">False</property> + <property name="fill">True</property> + <property name="pack_type">end</property> + <property name="position">0</property> + </packing> + </child> + </object> + </child> + </object> +</interface>
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits