28#define GBW_STATE_OPTIONLIST 0
29#define GBW_STATE_DEFAULTOPTION 1
30#define GBW_STATE_OPTIONVALUES 2
31#define GBW_STATE_DBFIELD 3
32#define GBW_STATE_FINALIZE 4
42 const Reference< XPropertySet >& _rxObjectModel,
const Reference< XComponentContext >& _rxContext )
44 , m_bVisitedDefault(false)
58 return FormComponentType::GROUPBOX == _nClassId;
63 OUString sIdent(OUString::number(_nState));
69 return std::make_unique<ORadioSelectionPage>(pPageContainer,
this);
72 return std::make_unique<ODefaultFieldSelectionPage>(pPageContainer,
this);
75 return std::make_unique<OOptionValuesPage>(pPageContainer,
this);
78 return std::make_unique<OOptionDBFieldPage>(pPageContainer,
this);
81 return std::make_unique<OFinalizeGBWPage>(pPageContainer,
this);
89 switch (_nCurrentState)
163 "caught an exception while creating the radio shapes!");
170 :
OGBWPage(pPage, pWizard,
"modules/sabpilot/ui/groupradioselectionpage.ui",
"GroupRadioSelectionPage")
171 , m_xRadioName(m_xBuilder->weld_entry(
"radiolabels"))
172 , m_xMoveRight(m_xBuilder->weld_button(
"toright"))
173 , m_xMoveLeft(m_xBuilder->weld_button(
"toleft"))
174 , m_xExistingRadios(m_xBuilder->weld_tree_view(
"radiobuttons"))
230 rSettings.
aValues.push_back(OUString::number(
i + 1));
238 bool bMoveLeft = (m_xMoveLeft.get() == &rButton);
241 while (m_xExistingRadios->count_selected_rows())
242 m_xExistingRadios->remove(m_xExistingRadios->get_selected_index());
246 m_xExistingRadios->append_text(m_xRadioName->get_text());
247 m_xRadioName->set_text(
"");
250 implCheckMoveButtons();
254 m_xExistingRadios->grab_focus();
256 m_xRadioName->grab_focus();
261 implCheckMoveButtons();
266 implCheckMoveButtons();
278 bool bUnfinishedInput = !
m_xRadioName->get_text().isEmpty();
285 pDialogController->
enableButtons(WizardButtonFlags::NEXT, bHaveSome);
289 if (bUnfinishedInput)
302 :
OMaybeListSelectionPage(pPage, pWizard,
"modules/sabpilot/ui/defaultfieldselectionpage.ui",
"DefaultFieldSelectionPage")
303 , m_xDefSelYes(m_xBuilder->weld_radio_button(
"defaultselectionyes"))
304 , m_xDefSelNo(m_xBuilder->weld_radio_button(
"defaultselectionno"))
305 , m_xDefSelection(m_xBuilder->weld_combo_box(
"defselectionfield"))
340 :
OGBWPage(pPage, pWizard,
"modules/sabpilot/ui/optionvaluespage.ui",
"OptionValuesPage")
341 , m_xValue(m_xBuilder->weld_entry(
"optionvalue"))
342 , m_xOptions(m_xBuilder->weld_tree_view(
"radiobuttons"))
354 implTraveledOptions();
382 DBG_ASSERT(rSettings.
aLabels.size(),
"OOptionValuesPage::initializePage: no options!!");
383 DBG_ASSERT(rSettings.
aLabels.size() == rSettings.
aValues.size(),
"OOptionValuesPage::initializePage: inconsistent data!");
427 :
OGBWPage(pPage, pWizard,
"modules/sabpilot/ui/optionsfinalpage.ui",
"OptionsFinalPage")
428 , m_xName(m_xBuilder->weld_entry(
"nameit"))
const char *const aFieldNames[]
OControlWizard * getDialog()
virtual void initializePage() override
const OControlWizardContext & getContext() const
void enableFormDatasourceDisplay()
void initControlSettings(OControlWizardSettings *_pSettings)
void commitControlSettings(OControlWizardSettings const *_pSettings)
const css::uno::Reference< css::uno::XComponentContext > & getComponentContext() const
const OControlWizardContext & getContext() const
void setDescriptionText(const OUString &rDesc)
std::unique_ptr< weld::RadioButton > m_xDefSelNo
virtual void initializePage() override
ODefaultFieldSelectionPage(weld::Container *pPage, OControlWizard *pWizard)
std::unique_ptr< weld::RadioButton > m_xDefSelYes
virtual ~ODefaultFieldSelectionPage() override
OOptionGroupSettings & getSettings()
virtual bool commitPage(::vcl::WizardTypes::CommitPageReason _eReason) override
std::unique_ptr< weld::ComboBox > m_xDefSelection
virtual bool commitPage(::vcl::WizardTypes::CommitPageReason _eReason) override
OFinalizeGBWPage(weld::Container *pPage, OControlWizard *pWizard)
virtual bool canAdvance() const override
virtual void initializePage() override
virtual ~OFinalizeGBWPage() override
std::unique_ptr< weld::Entry > m_xName
OOptionGroupSettings & getSettings()
OGroupBoxWizard(weld::Window *_pParent, const css::uno::Reference< css::beans::XPropertySet > &_rxObjectModel, const css::uno::Reference< css::uno::XComponentContext > &_rxContext)
OOptionGroupSettings m_aSettings
virtual std::unique_ptr< BuilderPage > createPage(WizardState _nState) override
virtual WizardState determineNextState(WizardState _nCurrentState) const override
virtual bool approveControl(sal_Int16 _nClassId) override
virtual void enterState(WizardState _nState) override
virtual bool onFinish() override
OOptionGroupSettings & getSettings()
void implCommit(OUString &_rSelection)
void announceControls(weld::RadioButton &_rYesButton, weld::RadioButton &_rNoButton, weld::ComboBox &_rSelection)
void implInitialize(const OUString &_rSelection)
OOptionDBFieldPage(weld::Container *pPage, OControlWizard *pWizard)
virtual OUString & getDBFieldSetting() override
void doLayout(const OControlWizardContext &_rContext, const OOptionGroupSettings &_rSettings)
void implTraveledOptions()
std::unique_ptr< weld::TreeView > m_xOptions
virtual void initializePage() override
OOptionValuesPage(weld::Container *pPage, OControlWizard *pWizard)
virtual ~OOptionValuesPage() override
std::unique_ptr< weld::Entry > m_xValue
std::vector< OUString > m_aUncommittedValues
virtual bool commitPage(::vcl::WizardTypes::CommitPageReason _eReason) override
::vcl::WizardTypes::WizardState m_nLastSelection
std::unique_ptr< weld::Entry > m_xRadioName
std::unique_ptr< weld::Button > m_xMoveRight
virtual ~ORadioSelectionPage() override
virtual bool canAdvance() const override
std::unique_ptr< weld::TreeView > m_xExistingRadios
virtual bool commitPage(::vcl::WizardTypes::CommitPageReason _eReason) override
std::unique_ptr< weld::Button > m_xMoveLeft
virtual void initializePage() override
ORadioSelectionPage(weld::Container *pPage, OControlWizard *pWizard)
void implCheckMoveButtons()
virtual bool commitPage(WizardTypes::CommitPageReason _eReason) override
virtual void Activate() override
std::unique_ptr< weld::Button > m_xNextPage
std::unique_ptr< weld::Button > m_xCancel
void defaultButton(WizardButtonFlags _nWizardButtonFlags)
std::unique_ptr< weld::Button > m_xPrevPage
void enableButtons(WizardButtonFlags _nWizardButtonFlags, bool _bEnable)
std::unique_ptr< weld::Button > m_xFinish
virtual void enterState(WizardTypes::WizardState _nState)
void setTitleBase(const OUString &_rTitleBase)
virtual Dialog * getDialog() override
std::unique_ptr< weld::Assistant > m_xAssistant
virtual bool is_default_widget(const weld::Widget *pCandidate) const=0
#define DBG_ASSERT(sCon, aError)
#define TOOLS_WARN_EXCEPTION(area, stream)
#define GBW_STATE_DBFIELD
#define GBW_STATE_DEFAULTOPTION
#define GBW_STATE_OPTIONLIST
#define GBW_STATE_FINALIZE
#define GBW_STATE_OPTIONVALUES
constexpr OUStringLiteral HID_GROUPWIZARD_PREVIOUS
constexpr OUStringLiteral HID_GROUPWIZARD_FINISH
constexpr OUStringLiteral HID_GROUPWIZARD_NEXT
constexpr OUStringLiteral HID_GROUPWIZARD_CANCEL
#define LINK(Instance, Class, Member)
OUString ModuleRes(TranslateId pId)
IMPL_LINK_NOARG(OTableSelectionPage, OnSearchClicked, weld::Button &, void)
IMPL_LINK(OTableSelectionPage, OnListboxDoubleClicked, weld::TreeView &, _rBox, bool)
constexpr std::enable_if_t< std::is_signed_v< T >, std::make_unsigned_t< T > > make_unsigned(T value)
css::uno::Sequence< OUString > aFieldNames
std::vector< OUString > aLabels
std::vector< OUString > aValues
#define WZS_INVALID_STATE