[Libreoffice-commits] .: Branch 'feature/template-dialog' - 2 commits - sfx2/inc sfx2/source svtools/inc svtools/Library_svt.mk svtools/Package_inc.mk svtools/source
Rafael Dominguez
rdominguez at kemper.freedesktop.org
Fri Jun 1 11:03:41 PDT 2012
sfx2/inc/templatedlg.hxx | 4 +++
sfx2/source/doc/templatedlg.cxx | 3 +-
sfx2/source/doc/templatedlg.hrc | 2 +
sfx2/source/doc/templatedlg.src | 9 +++++++-
svtools/Library_svt.mk | 9 ++++----
svtools/Package_inc.mk | 3 +-
svtools/inc/svtools/thumbnailview.hxx | 34 +++++++++++++++++++++++++++++++
svtools/source/control/thumbnailview.cxx | 28 +++++++++++++++++++++++++
8 files changed, 85 insertions(+), 7 deletions(-)
New commits:
commit 6cca1324d830caec26336856a77fe7a4fd7f7721
Author: Rafael Dominguez <venccsralph at gmail.com>
Date: Fri Jun 1 13:25:06 2012 -0430
Add thumbnail view to template dialog.
Change-Id: I72f31de4176f0ce5a721a1d21ae3ae936bcf296c
diff --git a/sfx2/inc/templatedlg.hxx b/sfx2/inc/templatedlg.hxx
index a0e893d..1317381 100644
--- a/sfx2/inc/templatedlg.hxx
+++ b/sfx2/inc/templatedlg.hxx
@@ -10,6 +10,8 @@
#ifndef TEMPLATEDLG_HXX
#define TEMPLATEDLG_HXX
+#include <svtools/thumbnailview.hxx>
+
#include <vcl/dialog.hxx>
#include <vcl/button.hxx>
@@ -34,6 +36,8 @@ private:
PushButton aButtonPresents;
PushButton aButtonSheets;
PushButton aButtonDraws;
+
+ ThumbnailView maView;
};
#endif // TEMPLATEDLG_HXX
diff --git a/sfx2/source/doc/templatedlg.cxx b/sfx2/source/doc/templatedlg.cxx
index 00d955d..18cad11 100644
--- a/sfx2/source/doc/templatedlg.cxx
+++ b/sfx2/source/doc/templatedlg.cxx
@@ -20,7 +20,8 @@ SfxTemplateManagerDlg::SfxTemplateManagerDlg (Window *parent)
aButtonDocs(this,SfxResId(BTN_SELECT_DOCS)),
aButtonPresents(this,SfxResId(BTN_SELECT_PRESENTATIONS)),
aButtonSheets(this,SfxResId(BTN_SELECT_SHEETS)),
- aButtonDraws(this,SfxResId(BTN_SELECT_DRAWS))
+ aButtonDraws(this,SfxResId(BTN_SELECT_DRAWS)),
+ maView(this,SfxResId(TEMPLATE_VIEW))
{
aButtonAll.SetClickHdl(LINK(this,SfxTemplateManagerDlg,ViewAllHdl));
aButtonDocs.SetClickHdl(LINK(this,SfxTemplateManagerDlg,ViewDocsHdl));
diff --git a/sfx2/source/doc/templatedlg.hrc b/sfx2/source/doc/templatedlg.hrc
index 5f0a277..78fe393 100644
--- a/sfx2/source/doc/templatedlg.hrc
+++ b/sfx2/source/doc/templatedlg.hrc
@@ -11,3 +11,5 @@
#define BTN_SELECT_PRESENTATIONS 3
#define BTN_SELECT_SHEETS 4
#define BTN_SELECT_DRAWS 5
+
+#define TEMPLATE_VIEW 6
diff --git a/sfx2/source/doc/templatedlg.src b/sfx2/source/doc/templatedlg.src
index 220a61d..85a8064 100644
--- a/sfx2/source/doc/templatedlg.src
+++ b/sfx2/source/doc/templatedlg.src
@@ -16,7 +16,7 @@ ModalDialog DLG_TEMPLATE_MANAGER
OutputSize = TRUE;
SVLook = TRUE;
Moveable = TRUE;
- Size = MAP_APPFONT ( 271 , 162 );
+ Size = MAP_APPFONT ( 270 , 165 );
Text [en-US] = "Template Manager";
PushButton BTN_SELECT_ALL
@@ -59,4 +59,11 @@ ModalDialog DLG_TEMPLATE_MANAGER
TabStop = TRUE;
Text [en-US] = "Drawings";
};
+
+ Control TEMPLATE_VIEW
+ {
+ Pos = MAP_APPFONT(5,30);
+ Size = MAP_APPFONT(50,260);
+ TabStop = TRUE;
+ };
};
commit c5e35498399fe169e52845226b556be4a0a101a6
Author: Rafael Dominguez <venccsralph at gmail.com>
Date: Fri Jun 1 12:45:58 2012 -0430
Create a new control to display thumbnails based on valueset.
Change-Id: I1f3df1a17afdef02fa40847cd879323f6341782b
diff --git a/svtools/Library_svt.mk b/svtools/Library_svt.mk
index 139e632..dd03c38 100644
--- a/svtools/Library_svt.mk
+++ b/svtools/Library_svt.mk
@@ -2,7 +2,7 @@
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2011 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -33,8 +33,8 @@ $(eval $(call gb_Library_use_package,svt,svtools_inc))
$(eval $(call gb_Library_set_componentfile,svt,svtools/util/svt))
$(eval $(call gb_Library_use_api,svt,\
- udkapi \
- offapi \
+ udkapi \
+ offapi \
))
$(eval $(call gb_Library_set_include,svt,\
@@ -69,7 +69,7 @@ $(eval $(call gb_Library_use_libraries,svt,\
))
$(eval $(call gb_Library_use_externals,svt,\
- icuuc \
+ icuuc \
jpeg \
))
@@ -129,6 +129,7 @@ $(eval $(call gb_Library_add_exception_objects,svt,\
svtools/source/control/stdctrl \
svtools/source/control/stdmenu \
svtools/source/control/tabbar \
+ svtools/source/control/thumbnailview \
svtools/source/control/toolbarmenu \
svtools/source/control/toolbarmenuacc \
svtools/source/control/urlcontrol \
diff --git a/svtools/Package_inc.mk b/svtools/Package_inc.mk
index 0dfc219..5cada8d 100644
--- a/svtools/Package_inc.mk
+++ b/svtools/Package_inc.mk
@@ -2,7 +2,7 @@
#*************************************************************************
#
# DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
-#
+#
# Copyright 2000, 2011 Oracle and/or its affiliates.
#
# OpenOffice.org - a multi-platform office productivity suite
@@ -161,6 +161,7 @@ $(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/textdata.hxx,svtools/t
$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/texteng.hxx,svtools/texteng.hxx))
$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/textview.hxx,svtools/textview.hxx))
$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/textwindowpeer.hxx,svtools/textwindowpeer.hxx))
+$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/thumbnailview.hxx,svtools/thumbnailview.hxx))
$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/toolbarmenu.hxx,svtools/toolbarmenu.hxx))
$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/toolboxcontroller.hxx,svtools/toolboxcontroller.hxx))
$(eval $(call gb_Package_add_file,svtools_inc,inc/svtools/toolpanel/decklayouter.hxx,svtools/toolpanel/decklayouter.hxx))
diff --git a/svtools/inc/svtools/thumbnailview.hxx b/svtools/inc/svtools/thumbnailview.hxx
new file mode 100644
index 0000000..5e2aba7
--- /dev/null
+++ b/svtools/inc/svtools/thumbnailview.hxx
@@ -0,0 +1,34 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Copyright 2012 LibreOffice contributors.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#ifndef THUMBNAILVIEW_HXX
+#define THUMBNAILVIEW_HXX
+
+#include <svtools/valueset.hxx>
+
+/**
+ *
+ * Class to display thumbnails with their names below their respective icons
+ *
+ **/
+
+class SVT_DLLPUBLIC ThumbnailView : public ValueSet
+{
+public:
+
+ ThumbnailView ( Window* pParent, WinBits nWinStyle = WB_ITEMBORDER, bool bDisableTransientChildren = false );
+
+ ThumbnailView ( Window* pParent, const ResId& rResId, bool bDisableTransientChildren = false );
+
+ virtual ~ThumbnailView ();
+};
+
+#endif // THUMBNAILVIEW_HXX
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
diff --git a/svtools/source/control/thumbnailview.cxx b/svtools/source/control/thumbnailview.cxx
new file mode 100644
index 0000000..041430d
--- /dev/null
+++ b/svtools/source/control/thumbnailview.cxx
@@ -0,0 +1,28 @@
+/* -*- Mode: C++; tab-width: 4; indent-tabs-mode: nil; c-basic-offset: 4 -*- */
+/*
+ * Copyright 2012 LibreOffice contributors.
+ *
+ * This Source Code Form is subject to the terms of the Mozilla Public
+ * License, v. 2.0. If a copy of the MPL was not distributed with this
+ * file, You can obtain one at http://mozilla.org/MPL/2.0/.
+ */
+
+#include <svtools/thumbnailview.hxx>
+
+ThumbnailView::ThumbnailView (Window *pParent, WinBits nWinStyle, bool bDisableTransientChildren)
+ : ValueSet(pParent,nWinStyle,bDisableTransientChildren)
+{
+}
+
+ThumbnailView::ThumbnailView (Window *pParent, const ResId &rResId, bool bDisableTransientChildren)
+ : ValueSet(pParent,rResId,bDisableTransientChildren)
+{
+}
+
+ThumbnailView::~ThumbnailView()
+{
+}
+
+/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
+
+
More information about the Libreoffice-commits
mailing list