#ifndef VCZH_PRESENTATION_CONTROLS_GUIRIBBONCONTROLS
#define VCZH_PRESENTATION_CONTROLS_GUIRIBBONCONTROLS
#include "GuiToolstripMenu.h"
#include "../GuiContainerControls.h"
#include "../ListControlPackage/GuiBindableListControls.h"
namespace
{
namespace
{
namespace
{
class
;
class
;
class
:
public
,
public
<
>
{
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonTabTemplate, GuiTab)
public
:
using
=
templates
::
;
private
:
templates
::
*
=
nullptr
;
void
BeforeControlTemplateUninstalled_
();
void
AfterControlTemplateInstalled_
(
bool
);
protected
:
void
BeforeControlTemplateUninstalled
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
AfterControlTemplateInstalled
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
CheckAndStoreControlTemplate
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonTabTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
*
TypedControlTemplateObject
(
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
compositions
::
* =
nullptr
;
compositions
::
* =
nullptr
;
public
:
(
theme
::
);
();
compositions
::
* ();
compositions
::
* ();
};
class
:
public
collections
::
<
*>
{
protected
:
*
=
nullptr
;
bool
(
,
*
const
&
)
override
;
void
(
,
*
const
&
)
override
;
void
(
,
)
override
;
public
:
(
*
);
~
GuiRibbonGroupCollection
();
};
class
:
public
,
public
<
>
{
friend
class
;
protected
:
bool
=
false
;
;
compositions
::
GuiResponsiveStackComposition
*
=
nullptr
;
compositions
::
GuiResponsiveContainerComposition
*
=
nullptr
;
compositions
::
*
=
nullptr
;
public
:
(
theme
::
);
();
compositions
::
;
bool
();
void
(
bool
);
collections
::
<
*>&
();
};
class
GuiRibbonGroupItemCollection
:
public
collections
::
<
*>
{
protected
:
*
=
nullptr
;
bool
(
,
*
const
&
)
override
;
void
(
,
*
const
&
)
override
;
void
(
,
)
override
;
public
:
GuiRibbonGroupItemCollection
(
*
);
~
GuiRibbonGroupItemCollection
();
};
class
:
public
,
protected
compositions
::
,
public
<
>
{
friend
class
GuiRibbonGroupItemCollection
;
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonGroupTemplate, GuiControl)
public
:
using
=
templates
::
;
private
:
templates
::
*
=
nullptr
;
void
BeforeControlTemplateUninstalled_
();
void
AfterControlTemplateInstalled_
(
bool
);
protected
:
void
BeforeControlTemplateUninstalled
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
AfterControlTemplateInstalled
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
CheckAndStoreControlTemplate
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonGroupTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
*
TypedControlTemplateObject
(
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
class
:
public
,
public
IRibbonGroupCommandExecutor
{
protected
:
*
;
public
:
(
*
);
();
void
()
override
;
};
bool
=
false
;
<
>
;
GuiRibbonGroupItemCollection
;
compositions
::
GuiResponsiveStackComposition
*
=
nullptr
;
compositions
::
*
=
nullptr
;
<
>
;
compositions
::
GuiResponsiveViewComposition
*
=
nullptr
;
compositions
::
GuiResponsiveFixedComposition
*
=
nullptr
;
*
=
nullptr
;
* =
nullptr
;
bool
()
override
;
compositions
::
*
()
override
;
void
(
compositions
::
*
,
compositions
::
&
);
void
(
compositions
::
*
,
compositions
::
&
);
void
(
compositions
::
*
,
compositions
::
&
);
void
(
compositions
::
* ,
compositions
::
& );
public
:
(
theme
::
);
();
compositions
::
;
compositions
::
;
compositions
::
;
bool
();
void
(
bool
);
<
>
();
void
(
<
>
);
collections
::
<
*>&
();
};
class
:
public
,
public
<
>
{
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonIconLabelTemplate, GuiControl)
public
:
using
=
templates
::
GuiRibbonIconLabelTemplate
;
private
:
templates
::
GuiRibbonIconLabelTemplate
*
=
nullptr
;
void
BeforeControlTemplateUninstalled_
();
void
AfterControlTemplateInstalled_
(
bool
);
protected
:
void
BeforeControlTemplateUninstalled
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
AfterControlTemplateInstalled
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
CheckAndStoreControlTemplate
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
GuiRibbonIconLabelTemplate
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonIconLabelTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
GuiRibbonIconLabelTemplate
*
TypedControlTemplateObject
(
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
<
>
;
public
:
(
theme
::
);
();
compositions
::
;
<
>
();
void
(
<
>
);
};
enum
class
{
=
0
,
=
1
,
=
2
,
};
class
;
class
:
public
collections
::
<
*>
{
protected
:
*
=
nullptr
;
bool
(
,
*
const
&
)
override
;
void
(
,
*
const
&
)
override
;
void
(
,
*
const
&
)
override
;
public
:
(
*
);
();
};
class
:
public
,
public
<
>
{
friend
class
GuiRibbonButtonsItemCollection
;
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonButtonsTemplate, GuiControl)
public
:
using
=
templates
::
;
private
:
templates
::
*
=
nullptr
;
void
();
void
(
bool
);
protected
:
void
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonButtonsTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
*
(
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
;
;
compositions
::
GuiResponsiveViewComposition
*
=
nullptr
;
compositions
::
GuiResponsiveFixedComposition
*
[
3
] = {
nullptr
,
nullptr
,
nullptr
};
GuiRibbonButtonsItemCollection
;
void
(
compositions
::
*
,
compositions
::
&
);
void
(
compositions
::
GuiResponsiveCompositionBase
*
,
*
);
public
:
(
theme
::
,
,
);
();
collections
::
<
*>&
();
};
class
;
class
:
public
collections
::
<
*>
{
protected
:
*
=
nullptr
;
bool
(
,
*
const
&
)
override
;
void
(
,
*
const
&
)
override
;
void
(
,
)
override
;
public
:
(
*
);
();
};
class
:
public
,
public
<
>
{
friend
class
GuiRibbonToolstripsGroupCollection
;
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonToolstripsTemplate, GuiControl)
public
:
using
=
templates
::
GuiRibbonToolstripsTemplate
;
private
:
templates
::
GuiRibbonToolstripsTemplate
*
=
nullptr
;
void
();
void
(
bool
);
protected
:
void
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
GuiRibbonToolstripsTemplate
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonToolstripsTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
GuiRibbonToolstripsTemplate
*
(
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
compositions
::
GuiResponsiveViewComposition
*
=
nullptr
;
*
[
5
] = {
nullptr
,
nullptr
,
nullptr
,
nullptr
,
nullptr
};
GuiToolstripGroupContainer
*
[
2
] = {
nullptr
,
nullptr
};
GuiToolstripGroupContainer
*
[
3
] = {
nullptr
,
nullptr
,
nullptr
};
compositions
::
GuiResponsiveFixedComposition
*
[
2
] = {
nullptr
,
nullptr
};
GuiRibbonToolstripsGroupCollection
;
void
(
compositions
::
*
,
compositions
::
&
);
void
(
= -
1
);
public
:
(
theme
::
);
();
collections
::
<
*>&
();
};
class
:
public
,
public
<
>
{
using
=
templates
::
;
using
=
<
templates
::
>;
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonGalleryTemplate, GuiControl)
public
:
using
=
templates
::
;
private
:
templates
::
*
=
nullptr
;
void
BeforeControlTemplateUninstalled_
();
void
AfterControlTemplateInstalled_
(
bool
);
protected
:
void
BeforeControlTemplateUninstalled
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
AfterControlTemplateInstalled
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
CheckAndStoreControlTemplate
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonGalleryTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
*
TypedControlTemplateObject
(
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
class
:
public
,
public
IRibbonGalleryCommandExecutor
{
protected
:
*
;
public
:
(
*
);
();
void
()
override
;
void
()
override
;
void
()
override
;
};
bool
=
true
;
bool
=
true
;
<
>
;
public
:
(
theme
::
);
();
compositions
::
;
compositions
::
;
compositions
::
;
compositions
::
;
compositions
::
;
bool
();
void
(
bool
);
bool
();
void
(
bool
);
};
class
:
public
,
public
<
>
{
GUI_SPECIFY_CONTROL_TEMPLATE_TYPE(RibbonToolstripMenuTemplate, GuiToolstripMenu)
public
:
using
=
templates
::
GuiRibbonToolstripMenuTemplate
;
private
:
templates
::
GuiRibbonToolstripMenuTemplate
* =
nullptr
;
void
();
void
(
bool
);
protected
:
void
()
override
{
BeforeControlTemplateUninstalled_
();
::
BeforeControlTemplateUninstalled
(); }
void
(
bool
)
override
{
::
AfterControlTemplateInstalled
(
);
AfterControlTemplateInstalled_
(
); }
void
(
templates
::
*
)
override
{
auto
=
dynamic_cast
<
templates
::
GuiRibbonToolstripMenuTemplate
*>(
);
do
{
if
(!(
ct
))
throw
(
L"The assigned control template is not vl::presentation::templates::Gui"
L"RibbonToolstripMenuTemplate"
L"."
);}
while
(
0
);
=
ct
;
::
CheckAndStoreControlTemplate
(
); }
public
:
templates
::
GuiRibbonToolstripMenuTemplate
* (
bool
) {
if
(
) {
EnsureControlTemplateExists
(); }
return
; }
private
:
protected
:
compositions
::
* ;
public
:
(
theme
::
,
* );
();
compositions
::
* ();
};
}
}
}
#endif