Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
core
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
LibreOffice
core
Commits
d039c481
Kaydet (Commit)
d039c481
authored
Mar 29, 2016
tarafından
Jan Holesovsky
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
notebookbar: Rename NotebookBarWindow to NotebookBar, and move accordingly.
Change-Id: If04a8f62aba0bcb712ae6405db318a4bd073fc54
üst
1fb31483
Hide whitespace changes
Inline
Side-by-side
Showing
8 changed files
with
45 additions
and
41 deletions
+45
-41
notebookbar.hxx
include/vcl/notebookbar.hxx
+6
-8
syswin.hxx
include/vcl/syswin.hxx
+5
-3
NotebookBarChildWindow.cxx
sfx2/source/notebookbar/NotebookBarChildWindow.cxx
+3
-2
Library_vcl.mk
vcl/Library_vcl.mk
+1
-1
brdwin.hxx
vcl/inc/brdwin.hxx
+4
-3
notebookbar.cxx
vcl/source/control/notebookbar.cxx
+7
-8
brdwin.cxx
vcl/source/window/brdwin.cxx
+8
-12
syswin.cxx
vcl/source/window/syswin.cxx
+11
-4
No files found.
vcl/source/window/notebookbarwindow
.hxx
→
include/vcl/notebookbar
.hxx
Dosyayı görüntüle @
d039c481
...
...
@@ -7,20 +7,18 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#ifndef VCL_SOURCE_WINDOW_NOTEBOOKBARWINDOW_HXX
#define VCL_SOURCE_WINDOW_NOTEBOOKBARWINDOW_HXX
#include "menuwindow.hxx"
#ifndef INCLUDED_VCL_NOTEBOOKBAR_HXX
#define INCLUDED_VCL_NOTEBOOKBAR_HXX
#include <vcl/builder.hxx>
#include <vcl/ctrl.hxx>
/// This implements Widget Layout-based notebook-like menu bar.
class
NotebookBar
Window
:
public
Control
,
public
VclBuilderContainer
class
NotebookBar
:
public
Control
,
public
VclBuilderContainer
{
public
:
NotebookBar
Window
(
Window
*
pParent
,
const
OString
&
rID
,
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>
&
rFrame
);
virtual
~
NotebookBar
Window
();
NotebookBar
(
Window
*
pParent
,
const
OString
&
rID
,
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>
&
rFrame
);
virtual
~
NotebookBar
();
virtual
void
dispose
()
SAL_OVERRIDE
;
virtual
Size
GetOptimalSize
()
const
SAL_OVERRIDE
;
...
...
@@ -29,6 +27,6 @@ public:
virtual
void
StateChanged
(
StateChangedType
nType
)
override
;
};
#endif //
VCL_SOURCE_WINDOW_NOTEBOOKBARWINDOW
_HXX
#endif //
INCLUDED_VCL_NOTEBOOKBAR
_HXX
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
include/vcl/syswin.hxx
Dosyayı görüntüle @
d039c481
...
...
@@ -23,12 +23,12 @@
#include <tools/solar.h>
#include <vcl/dllapi.h>
#include <vcl/builder.hxx>
#include <vcl/window.hxx>
#include <vcl/idle.hxx>
#include <vcl/notebookbar.hxx>
#include <vcl/window.hxx>
class
ModalDialog
;
class
MenuBar
;
class
NotebookBarWindow
;
class
TaskPaneList
;
class
VclContainer
;
...
...
@@ -153,6 +153,7 @@ private:
sal_uInt16
mnIcon
;
ImplData
*
mpImplData
;
Idle
maLayoutIdle
;
OUString
maNotebookBarUIFile
;
protected
:
bool
mbIsDefferedInit
;
VclPtr
<
vcl
::
Window
>
mpDialogParent
;
...
...
@@ -227,7 +228,8 @@ public:
MenuBar
*
GetMenuBar
()
const
{
return
mpMenuBar
;
}
void
SetMenuBarMode
(
MenuBarMode
nMode
);
VclPtr
<
vcl
::
Window
>
CreateNotebookBar
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
);
void
SetNotebookBar
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
);
VclPtr
<
NotebookBar
>
GetNotebookBar
()
const
;
TaskPaneList
*
GetTaskPaneList
();
void
GetWindowStateData
(
WindowStateData
&
rData
)
const
;
...
...
sfx2/source/notebookbar/NotebookBarChildWindow.cxx
Dosyayı görüntüle @
d039c481
...
...
@@ -23,9 +23,10 @@ NotebookBarChildWindow::NotebookBarChildWindow (vcl::Window* pParentWindow, sal_
:
SfxChildWindow
(
pParentWindow
,
nId
)
{
SfxFrame
&
rFrame
=
pBindings
->
GetDispatcher_Impl
()
->
GetFrame
()
->
GetFrame
();
VclPtr
<
vcl
::
Window
>
pNotebookBarWindow
=
rFrame
.
GetSystemWindow
()
->
Create
NotebookBar
(
"vcl/ui/notebookbar.ui"
,
rFrame
.
GetFrameInterface
());
rFrame
.
GetSystemWindow
()
->
Set
NotebookBar
(
"vcl/ui/notebookbar.ui"
,
rFrame
.
GetFrameInterface
());
pNotebookBarWindow
->
SetHelpId
(
HID_NOTEBOOKBAR_WINDOW
);
VclPtr
<
NotebookBar
>
pNotebookBar
(
rFrame
.
GetSystemWindow
()
->
GetNotebookBar
());
pNotebookBar
->
SetHelpId
(
HID_NOTEBOOKBAR_WINDOW
);
}
/* vim:set shiftwidth=4 softtabstop=4 expandtab: */
vcl/Library_vcl.mk
Dosyayı görüntüle @
d039c481
...
...
@@ -170,7 +170,6 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\
vcl/source/window/mouse \
vcl/source/window/mouseevent \
vcl/source/window/msgbox \
vcl/source/window/notebookbarwindow \
vcl/source/window/popupmenuwindow \
vcl/source/window/printdlg \
vcl/source/window/scrwnd \
...
...
@@ -205,6 +204,7 @@ $(eval $(call gb_Library_add_exception_objects,vcl,\
vcl/source/control/listbox \
vcl/source/control/menubtn \
vcl/source/control/morebtn \
vcl/source/control/notebookbar \
vcl/source/control/quickselectionengine \
vcl/source/control/prgsbar \
vcl/source/control/scrbar \
...
...
vcl/inc/brdwin.hxx
Dosyayı görüntüle @
d039c481
...
...
@@ -20,13 +20,13 @@
#ifndef INCLUDED_VCL_INC_BRDWIN_HXX
#define INCLUDED_VCL_INC_BRDWIN_HXX
#include <vcl/notebookbar.hxx>
#include <vcl/window.hxx>
#include <com/sun/star/frame/XFrame.hpp>
class
ImplBorderWindowView
;
enum
class
DrawButtonFlags
;
class
NotebookBarWindow
;
#define BORDERWINDOW_STYLE_OVERLAP ((sal_uInt16)0x0001)
#define BORDERWINDOW_STYLE_BORDER ((sal_uInt16)0x0002)
...
...
@@ -88,7 +88,7 @@ class ImplBorderWindow : public vcl::Window
private
:
ImplBorderWindowView
*
mpBorderView
;
VclPtr
<
vcl
::
Window
>
mpMenuBarWindow
;
VclPtr
<
NotebookBar
Window
>
mpNotebookBarWindow
;
VclPtr
<
NotebookBar
>
mpNotebookBar
;
long
mnMinWidth
;
long
mnMinHeight
;
long
mnMaxWidth
;
...
...
@@ -162,7 +162,8 @@ public:
void
SetMenuBarWindow
(
vcl
::
Window
*
pWindow
);
void
SetMenuBarMode
(
bool
bHide
);
VclPtr
<
vcl
::
Window
>
CreateNotebookBarWindow
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
);
void
SetNotebookBar
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
);
VclPtr
<
NotebookBar
>
GetNotebookBar
()
const
{
return
mpNotebookBar
;
}
void
SetMinOutputSize
(
long
nWidth
,
long
nHeight
)
{
mnMinWidth
=
nWidth
;
mnMinHeight
=
nHeight
;
}
...
...
vcl/source/
window/notebookbarwindow
.cxx
→
vcl/source/
control/notebookbar
.cxx
Dosyayı görüntüle @
d039c481
...
...
@@ -7,29 +7,28 @@
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#include "notebookbarwindow.hxx"
#include <vcl/layout.hxx>
#include <vcl/notebookbar.hxx>
NotebookBar
Window
::
NotebookBarWindow
(
Window
*
pParent
,
const
OString
&
rID
,
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>
&
rFrame
)
NotebookBar
::
NotebookBar
(
Window
*
pParent
,
const
OString
&
rID
,
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>
&
rFrame
)
:
Control
(
pParent
)
{
SetStyle
(
GetStyle
()
|
WB_DIALOGCONTROL
);
m_pUIBuilder
=
new
VclBuilder
(
this
,
getUIRootDir
(),
rUIXMLDescription
,
rID
,
rFrame
);
}
NotebookBar
Window
::~
NotebookBarWindow
()
NotebookBar
::~
NotebookBar
()
{
disposeOnce
();
}
void
NotebookBar
Window
::
dispose
()
void
NotebookBar
::
dispose
()
{
disposeBuilder
();
Control
::
dispose
();
}
Size
NotebookBar
Window
::
GetOptimalSize
()
const
Size
NotebookBar
::
GetOptimalSize
()
const
{
if
(
isLayoutEnabled
(
this
))
return
VclContainer
::
getLayoutRequisition
(
*
GetWindow
(
GetWindowType
::
FirstChild
));
...
...
@@ -37,7 +36,7 @@ Size NotebookBarWindow::GetOptimalSize() const
return
Control
::
GetOptimalSize
();
}
void
NotebookBar
Window
::
setPosSizePixel
(
long
nX
,
long
nY
,
long
nWidth
,
long
nHeight
,
PosSizeFlags
nFlags
)
void
NotebookBar
::
setPosSizePixel
(
long
nX
,
long
nY
,
long
nWidth
,
long
nHeight
,
PosSizeFlags
nFlags
)
{
bool
bCanHandleSmallerWidth
=
false
;
bool
bCanHandleSmallerHeight
=
false
;
...
...
@@ -66,7 +65,7 @@ void NotebookBarWindow::setPosSizePixel(long nX, long nY, long nWidth, long nHei
VclContainer
::
setLayoutAllocation
(
*
pChild
,
Point
(
0
,
0
),
Size
(
nWidth
,
nHeight
));
}
void
NotebookBar
Window
::
StateChanged
(
StateChangedType
nType
)
void
NotebookBar
::
StateChanged
(
StateChangedType
nType
)
{
if
(
nType
==
StateChangedType
::
Visible
)
{
...
...
vcl/source/window/brdwin.cxx
Dosyayı görüntüle @
d039c481
...
...
@@ -37,8 +37,6 @@
#include <vcl/metric.hxx>
#include <vcl/settings.hxx>
#include "notebookbarwindow.hxx"
using
namespace
::
com
::
sun
::
star
::
uno
;
// useful caption height for title bar buttons
...
...
@@ -1834,7 +1832,7 @@ void ImplBorderWindow::dispose()
delete
mpBorderView
;
mpBorderView
=
nullptr
;
mpMenuBarWindow
.
clear
();
mpNotebookBar
Window
.
disposeAndClear
();
mpNotebookBar
.
disposeAndClear
();
vcl
::
Window
::
dispose
();
}
...
...
@@ -1944,10 +1942,10 @@ void ImplBorderWindow::Resize()
nTopBorder
+=
nMenuHeight
;
}
if
(
mpNotebookBar
Window
)
if
(
mpNotebookBar
)
{
long
nNotebookBarHeight
=
mpNotebookBar
Window
->
GetSizePixel
().
Height
();
mpNotebookBar
Window
->
setPosSizePixel
(
long
nNotebookBarHeight
=
mpNotebookBar
->
GetSizePixel
().
Height
();
mpNotebookBar
->
setPosSizePixel
(
nLeftBorder
,
nTopBorder
,
aSize
.
Width
()
-
nLeftBorder
-
nRightBorder
,
nNotebookBarHeight
);
...
...
@@ -2177,12 +2175,10 @@ void ImplBorderWindow::SetMenuBarMode( bool bHide )
UpdateMenuHeight
();
}
VclPtr
<
vcl
::
Window
>
ImplBorderWindow
::
CreateNotebookBarWindow
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
)
void
ImplBorderWindow
::
SetNotebookBar
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
)
{
mpNotebookBar
Window
=
VclPtr
<
NotebookBarWindow
>::
Create
(
this
,
"NotebookBar"
,
rUIXMLDescription
,
rFrame
);
mpNotebookBar
=
VclPtr
<
NotebookBar
>::
Create
(
this
,
"NotebookBar"
,
rUIXMLDescription
,
rFrame
);
Resize
();
return
mpNotebookBarWindow
;
}
void
ImplBorderWindow
::
GetBorder
(
sal_Int32
&
rLeftBorder
,
sal_Int32
&
rTopBorder
,
...
...
@@ -2193,8 +2189,8 @@ void ImplBorderWindow::GetBorder( sal_Int32& rLeftBorder, sal_Int32& rTopBorder,
if
(
mpMenuBarWindow
&&
!
mbMenuHide
)
rTopBorder
+=
mpMenuBarWindow
->
GetSizePixel
().
Height
();
if
(
mpNotebookBar
Window
&&
mpNotebookBarWindow
->
IsVisible
())
rTopBorder
+=
mpNotebookBar
Window
->
GetSizePixel
().
Height
();
if
(
mpNotebookBar
&&
mpNotebookBar
->
IsVisible
())
rTopBorder
+=
mpNotebookBar
->
GetSizePixel
().
Height
();
}
long
ImplBorderWindow
::
CalcTitleWidth
()
const
...
...
vcl/source/window/syswin.cxx
Dosyayı görüntüle @
d039c481
...
...
@@ -39,8 +39,6 @@
#include <brdwin.hxx>
#include <window.h>
#include "notebookbarwindow.hxx"
using
namespace
::
com
::
sun
::
star
::
uno
;
using
namespace
::
com
::
sun
::
star
::
lang
;
...
...
@@ -940,9 +938,18 @@ void SystemWindow::SetMenuBar(MenuBar* pMenuBar)
}
}
VclPtr
<
vcl
::
Window
>
SystemWindow
::
CreateNotebookBar
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
)
void
SystemWindow
::
SetNotebookBar
(
const
OUString
&
rUIXMLDescription
,
const
css
::
uno
::
Reference
<
css
::
frame
::
XFrame
>&
rFrame
)
{
if
(
rUIXMLDescription
!=
maNotebookBarUIFile
)
{
static_cast
<
ImplBorderWindow
*>
(
mpWindowImpl
->
mpBorderWindow
.
get
())
->
SetNotebookBar
(
rUIXMLDescription
,
rFrame
);
maNotebookBarUIFile
=
rUIXMLDescription
;
}
}
VclPtr
<
NotebookBar
>
SystemWindow
::
GetNotebookBar
()
const
{
return
static_cast
<
ImplBorderWindow
*>
(
mpWindowImpl
->
mpBorderWindow
.
get
())
->
CreateNotebookBarWindow
(
rUIXMLDescription
,
rFrame
);
return
static_cast
<
ImplBorderWindow
*>
(
mpWindowImpl
->
mpBorderWindow
.
get
())
->
GetNotebookBar
(
);
}
void
SystemWindow
::
SetMenuBarMode
(
MenuBarMode
nMode
)
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment