Kaydet (Commit) bd225bc2 authored tarafından Caolán McNamara's avatar Caolán McNamara

convert gallery search progress dialog to .ui

Change-Id: I77d9530ebc6529d87e2484c8440794e246aab5b9
üst 0240aa98
......@@ -42,6 +42,7 @@ $(eval $(call gb_UIConfig_add_uifiles,cui,\
cui/uiconfig/ui/dbregisterpage \
cui/uiconfig/ui/effectspage \
cui/uiconfig/ui/formatcellsdialog \
cui/uiconfig/ui/gallerysearchprogress \
cui/uiconfig/ui/gallerythemeiddialog \
cui/uiconfig/ui/gallerytitledialog \
cui/uiconfig/ui/hangulhanjaadddialog \
......
......@@ -204,17 +204,16 @@ void SearchThread::ImplSearch( const INetURLObject& rStartURL,
// - SearchProgress -
// ------------------
SearchProgress::SearchProgress( Window* pParent, const INetURLObject& rStartURL ) :
ModalDialog ( pParent, CUI_RES(RID_SVXDLG_GALLERY_SEARCH_PROGRESS ) ),
aFtSearchDir ( this, CUI_RES( FT_SEARCH_DIR ) ),
aFLSearchDir ( this, CUI_RES( FL_SEARCH_DIR ) ),
aFtSearchType ( this, CUI_RES( FT_SEARCH_TYPE ) ),
aFLSearchType ( this, CUI_RES( FL_SEARCH_TYPE ) ),
aBtnCancel ( this, CUI_RES( BTN_CANCEL ) ),
parent_(pParent), startUrl_(rStartURL)
SearchProgress::SearchProgress( Window* pParent, const INetURLObject& rStartURL )
: ModalDialog(pParent, "GallerySearchProgress", "cui/ui/gallerysearchprogress.ui")
, parent_(pParent)
, startUrl_(rStartURL)
{
FreeResource();
aBtnCancel.SetClickHdl( LINK( this, SearchProgress, ClickCancelBtn ) );
get(m_pFtSearchDir, "dir");
get(m_pFtSearchType, "file");
m_pFtSearchType->set_width_request(m_pFtSearchType->get_preferred_size().Width());
get(m_pBtnCancel, "cancel");
m_pBtnCancel->SetClickHdl( LINK( this, SearchProgress, ClickCancelBtn ) );
}
// ------------------------------------------------------------------------
......
......@@ -219,47 +219,6 @@ TabPage RID_SVXTABPAGE_GALLERYTHEME_FILES
/******************************************************************************/
ModalDialog RID_SVXDLG_GALLERY_SEARCH_PROGRESS
{
HelpId = HID_GALLERY_SEARCH ;
OutputSize = TRUE ;
Border = TRUE ;
SVLook = TRUE ;
Size = MAP_APPFONT ( 124 , 86 ) ;
Text [ en-US ] = "Find" ;
Moveable = TRUE ;
FixedLine FL_SEARCH_DIR
{
Pos = MAP_APPFONT ( 6 , 33 ) ;
Size = MAP_APPFONT ( 112 , 8 ) ;
Text [ en-US ] = "Directory" ;
};
FixedText FT_SEARCH_DIR
{
Pos = MAP_APPFONT ( 12 , 44 ) ;
Size = MAP_APPFONT ( 100 , 10 ) ;
};
CancelButton BTN_CANCEL
{
Pos = MAP_APPFONT ( 37 , 66 ) ;
Size = MAP_APPFONT ( 50 , 14 ) ;
TabStop = TRUE ;
};
FixedLine FL_SEARCH_TYPE
{
Pos = MAP_APPFONT ( 6 , 3 ) ;
Size = MAP_APPFONT ( 112 , 8 ) ;
Text [ en-US ] = "File type" ;
};
FixedText FT_SEARCH_TYPE
{
Pos = MAP_APPFONT ( 12 , 14 ) ;
Size = MAP_APPFONT ( 100 , 10 ) ;
};
};
/******************************************************************************/
ModalDialog RID_SVXDLG_GALLERY_TAKE_PROGRESS
{
HelpId = HID_GALLERY_APPLY ;
......
......@@ -80,12 +80,9 @@ public:
class SearchProgress : public ModalDialog
{
private:
FixedText aFtSearchDir;
FixedLine aFLSearchDir;
FixedText aFtSearchType;
FixedLine aFLSearchType;
CancelButton aBtnCancel;
FixedText* m_pFtSearchDir;
FixedText* m_pFtSearchType;
CancelButton* m_pBtnCancel;
Window * parent_;
INetURLObject startUrl_;
rtl::Reference< SearchThread > maSearchThread;
......@@ -101,8 +98,8 @@ public:
virtual short Execute();
virtual void StartExecuteModal( const Link& rEndDialogHdl );
void SetFileType( const OUString& rType ) { aFtSearchType.SetText( rType ); }
void SetDirectory( const INetURLObject& rURL ) { aFtSearchDir.SetText( GetReducedString( rURL, 30 ) ); }
void SetFileType( const OUString& rType ) { m_pFtSearchType->SetText( rType ); }
void SetDirectory( const INetURLObject& rURL ) { m_pFtSearchDir->SetText( GetReducedString( rURL, 30 ) ); }
};
class TakeThread: public salhelper::Thread
......
......@@ -25,7 +25,6 @@
#define RID_SVXTABPAGE_GALLERYTHEME_FILES (RID_CUI_GALLERY_START + 4)
// Dialogs
#define RID_SVXDLG_GALLERY_SEARCH_PROGRESS (RID_CUI_GALLERY_START + 6)
#define RID_SVXDLG_GALLERY_TAKE_PROGRESS (RID_CUI_GALLERY_START + 7)
#define RID_SVXDLG_GALLERY_ACTUALIZE_PROGRESS (RID_CUI_GALLERY_START + 8)
......@@ -53,10 +52,6 @@
#define CBX_PREVIEW 3
#define FT_FILETYPE 2
#define CBB_FILETYPE 1
#define FL_SEARCH_DIR 1
#define FL_SEARCH_TYPE 2
#define FT_SEARCH_DIR 1
#define FT_SEARCH_TYPE 2
#define FL_TAKE_PROGRESS 1
#define FT_TAKE_FILE 1
#define BTN_TAKEALL 1
......
......@@ -183,7 +183,6 @@
#define HID_SEARCH_BTN_SEARCH "CUI_HID_SEARCH_BTN_SEARCH"
#define HID_SEARCH_BTN_CLOSE "CUI_HID_SEARCH_BTN_CLOSE"
#define HID_GALLERY_BROWSER "CUI_HID_GALLERY_BROWSER"
#define HID_GALLERY_SEARCH "CUI_HID_GALLERY_SEARCH"
#define HID_GALLERY_APPLY "CUI_HID_GALLERY_APPLY"
#define HID_CONFIG_ACCEL "CUI_HID_CONFIG_ACCEL"
#define HID_ACCELCONFIG_LISTBOX "CUI_HID_ACCELCONFIG_LISTBOX"
......
<?xml version="1.0" encoding="UTF-8"?>
<interface>
<!-- interface-requires gtk+ 3.0 -->
<object class="GtkDialog" id="GallerySearchProgress">
<property name="can_focus">False</property>
<property name="border_width">6</property>
<property name="title" translatable="yes">Find</property>
<property name="type_hint">dialog</property>
<child internal-child="vbox">
<object class="GtkBox" id="dialog-vbox1">
<property name="can_focus">False</property>
<property name="orientation">vertical</property>
<property name="spacing">12</property>
<child internal-child="action_area">
<object class="GtkButtonBox" id="dialog-action_area1">
<property name="can_focus">False</property>
<property name="layout_style">end</property>
<child>
<object class="GtkButton" id="cancel">
<property name="label">gtk-cancel</property>
<property name="visible">True</property>
<property name="can_focus">True</property>
<property name="can_default">True</property>
<property name="has_default">True</property>
<property name="receives_default">True</property>
<property name="use_stock">True</property>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</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>
<child>
<object class="GtkGrid" id="grid1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="row_spacing">12</property>
<child>
<object class="GtkFrame" id="frame1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkLabel" id="file">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="xalign">0</property>
<property name="ellipsize">end</property>
<property name="width_chars">40</property>
<property name="single_line_mode">True</property>
<property name="max_width_chars">40</property>
</object>
</child>
</object>
</child>
<child type="label">
<object class="GtkLabel" id="label1">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">File type</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
</object>
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">0</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
<child>
<object class="GtkFrame" id="frame2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label_xalign">0</property>
<property name="shadow_type">none</property>
<child>
<object class="GtkAlignment" id="alignment2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="top_padding">6</property>
<property name="left_padding">12</property>
<child>
<object class="GtkLabel" id="dir">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="width_chars">40</property>
</object>
</child>
</object>
</child>
<child type="label">
<object class="GtkLabel" id="label2">
<property name="visible">True</property>
<property name="can_focus">False</property>
<property name="label" translatable="yes">Directory</property>
<attributes>
<attribute name="weight" value="bold"/>
</attributes>
</object>
</child>
</object>
<packing>
<property name="left_attach">0</property>
<property name="top_attach">1</property>
<property name="width">1</property>
<property name="height">1</property>
</packing>
</child>
</object>
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
<property name="position">1</property>
</packing>
</child>
</object>
</child>
<action-widgets>
<action-widget response="0">cancel</action-widget>
</action-widgets>
</object>
</interface>
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