Skip to content
This repository was archived by the owner on Jun 29, 2020. It is now read-only.
This repository was archived by the owner on Jun 29, 2020. It is now read-only.

Getters for UI-elements in generated UI-class #8

@cls-nebadje

Description

@cls-nebadje

Instead of exposing the actual pointers to the widgets, the generated UI-class should expose them through getters. This way we can prevent some self-injuries.

class Ui_foo
{
public:
    Wt::WContainerWidget *
    wt_root()
    {
        return m_wt_root;
    }
    ...
    Wt::WText *
    text()
    {
        return m_text;
    }
    void setupUi(Wt::WContainerWidget *PageRoot)
    {
        ...
    }
    ...
private:
    Wt::WContainerWidget *m_wt_root;
    Wt::WSlider *m_slider_volume;
    Wt::WPushButton *m_button;
    Wt::WText *m_text;
...
};

Regards
Uli

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions