summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorCaolán McNamara <caolanm@redhat.com>2014-10-09 17:07:43 +0100
committerCaolán McNamara <caolanm@redhat.com>2014-10-09 17:08:13 +0100
commitfe421533614cce6819c72c16f19b8de19e0d99da (patch)
tree5c2eb65f737e086d58514c1b2759b7e9c1864bd2
parentfab88063281761dbdac7ea550072660fe0f8c863 (diff)
Resolves: fdo#83003 provide a means to return from template view
Change-Id: Ie6d2cfb5ee28fbd9395a49fa074a252c9c6e20ec
-rw-r--r--sfx2/source/dialog/backingwindow.cxx7
-rw-r--r--sfx2/source/dialog/backingwindow.hxx1
-rw-r--r--sfx2/uiconfig/ui/startcenter.ui139
3 files changed, 90 insertions, 57 deletions
diff --git a/sfx2/source/dialog/backingwindow.cxx b/sfx2/source/dialog/backingwindow.cxx
index 0d5801d2106f..1e87b42a27a3 100644
--- a/sfx2/source/dialog/backingwindow.cxx
+++ b/sfx2/source/dialog/backingwindow.cxx
@@ -101,6 +101,7 @@ BackingWindow::BackingWindow( vcl::Window* i_pParent ) :
m_pUIBuilder = new VclBuilder(this, getUIRootDir(), "sfx/ui/startcenter.ui", "StartCenter" );
get(mpOpenButton, "open_all");
+ get(mpRecentButton, "open_recent");
get(mpTemplateButton, "templates_all");
get(mpCreateLabel, "create_label");
@@ -274,6 +275,7 @@ void BackingWindow::initControls()
mpLocalView->setOpenTemplateHdl(LINK(this,BackingWindow,OpenTemplateHdl));
setupButton( mpOpenButton );
+ setupButton( mpRecentButton );
setupButton( mpTemplateButton );
setupButton( mpWriterAllButton );
setupButton( mpDrawAllButton );
@@ -545,6 +547,11 @@ IMPL_LINK( BackingWindow, ClickHdl, Button*, pButton )
dispatchURL( OPEN_URL, OUString(), xFrame, aArgs );
}
+ else if( pButton == mpRecentButton )
+ {
+ mpLocalView->Hide();
+ mpAllRecentThumbnails->Show();
+ }
else if( pButton == mpTemplateButton )
{
mpAllRecentThumbnails->Hide();
diff --git a/sfx2/source/dialog/backingwindow.hxx b/sfx2/source/dialog/backingwindow.hxx
index 72c8a676d67f..cc1e9e53c20d 100644
--- a/sfx2/source/dialog/backingwindow.hxx
+++ b/sfx2/source/dialog/backingwindow.hxx
@@ -62,6 +62,7 @@ class BackingWindow
com::sun::star::uno::Reference< com::sun::star::datatransfer::dnd::XDropTargetListener > mxDropTargetListener;
PushButton* mpOpenButton;
+ PushButton* mpRecentButton;
MenuButton* mpTemplateButton;
FixedText* mpCreateLabel;
diff --git a/sfx2/uiconfig/ui/startcenter.ui b/sfx2/uiconfig/ui/startcenter.ui
index e23d8f8231ac..18660cecc6a9 100644
--- a/sfx2/uiconfig/ui/startcenter.ui
+++ b/sfx2/uiconfig/ui/startcenter.ui
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
-<!-- Generated with glade 3.16.0 on Fri Aug 8 17:26:41 2014 -->
+<!-- Generated with glade 3.16.1 -->
<interface>
- <!-- interface-requires gtk+ 3.0 -->
+ <requires lib="gtk+" version="3.0"/>
<!-- interface-requires LibreOffice 1.0 -->
<object class="GtkImage" id="calc_all_image">
<property name="visible">True</property>
@@ -18,6 +18,51 @@
<property name="can_focus">False</property>
<property name="pixbuf">res/odg_32_8.png</property>
</object>
+ <object class="GtkMenu" id="filtermenu">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <child>
+ <object class="GtkMenuItem" id="filter_writer">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Writer Templates</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkMenuItem" id="filter_calc">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Calc Templates</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkMenuItem" id="filter_impress">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Impress Templates</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkMenuItem" id="filter_draw">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Draw Templates</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkSeparatorMenuItem" id="menuitem3">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ </object>
+ </child>
+ <child>
+ <object class="GtkMenuItem" id="edit">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="label" translatable="yes">Edit Templates</property>
+ </object>
+ </child>
+ </object>
<object class="GtkImage" id="impress_all_image">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -33,6 +78,11 @@
<property name="can_focus">False</property>
<property name="pixbuf">framework/res/folder_32.png</property>
</object>
+ <object class="GtkImage" id="open_all_image1">
+ <property name="visible">True</property>
+ <property name="can_focus">False</property>
+ <property name="pixbuf">framework/res/folder_32.png</property>
+ </object>
<object class="GtkImage" id="templates_all_image">
<property name="visible">True</property>
<property name="can_focus">False</property>
@@ -86,6 +136,26 @@
</packing>
</child>
<child>
+ <object class="GtkButton" id="open_recent">
+ <property name="label" translatable="yes">_Recent Files</property>
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="margin_left">6</property>
+ <property name="margin_right">6</property>
+ <property name="margin_top">6</property>
+ <property name="image">open_all_image1</property>
+ <property name="relief">none</property>
+ <property name="use_underline">True</property>
+ <property name="xalign">0</property>
+ </object>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">True</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
+ <child>
<object class="GtkButton" id="templates_all:filtermenu">
<property name="label" translatable="yes">T_emplates</property>
<property name="visible">True</property>
@@ -101,7 +171,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">1</property>
+ <property name="position">2</property>
</packing>
</child>
<child>
@@ -114,7 +184,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">2</property>
+ <property name="position">3</property>
</packing>
</child>
<child>
@@ -129,7 +199,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">3</property>
+ <property name="position">4</property>
</packing>
</child>
<child>
@@ -149,7 +219,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">4</property>
+ <property name="position">5</property>
</packing>
</child>
<child>
@@ -169,7 +239,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">5</property>
+ <property name="position">6</property>
</packing>
</child>
<child>
@@ -189,7 +259,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">6</property>
+ <property name="position">7</property>
</packing>
</child>
<child>
@@ -209,7 +279,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">7</property>
+ <property name="position">8</property>
</packing>
</child>
<child>
@@ -229,7 +299,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">8</property>
+ <property name="position">9</property>
</packing>
</child>
<child>
@@ -249,7 +319,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">9</property>
+ <property name="position">10</property>
</packing>
</child>
<child>
@@ -260,7 +330,7 @@
<packing>
<property name="expand">False</property>
<property name="fill">True</property>
- <property name="position">10</property>
+ <property name="position">11</property>
</packing>
</child>
</object>
@@ -430,49 +500,4 @@
</packing>
</child>
</object>
- <object class="GtkMenu" id="filtermenu">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <child>
- <object class="GtkMenuItem" id="filter_writer">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Writer Templates</property>
- </object>
- </child>
- <child>
- <object class="GtkMenuItem" id="filter_calc">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Calc Templates</property>
- </object>
- </child>
- <child>
- <object class="GtkMenuItem" id="filter_impress">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Impress Templates</property>
- </object>
- </child>
- <child>
- <object class="GtkMenuItem" id="filter_draw">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Draw Templates</property>
- </object>
- </child>
- <child>
- <object class="GtkSeparatorMenuItem" id="menuitem3">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- </object>
- </child>
- <child>
- <object class="GtkMenuItem" id="edit">
- <property name="visible">True</property>
- <property name="can_focus">False</property>
- <property name="label" translatable="yes">Edit Templates</property>
- </object>
- </child>
- </object>
</interface>