Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add workbench.build experimental API #690

Merged
merged 1 commit into from
Oct 21, 2023
Merged

Add workbench.build experimental API #690

merged 1 commit into from
Oct 21, 2023

Conversation

sonnyp
Copy link
Contributor

@sonnyp sonnyp commented Oct 16, 2023

Fixes #667

Makes Workbench support signal handlers and closures for Gtk interface.
It uses https://github.com/sonnyp/troll#build

@@ -80,6 +81,10 @@ export default function Internal({
dropdown_preview_align.selected = 0;
preview(object);
},
build(params) {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I wonder if we should do this instead

Suggested change
build(params) {
build(interface, params) {

and use it like so:

Suggested change
build(params) {
workbench.build(workbench.interface, params);

It's a bit repetitive, but it's closer to whatever "standard" API we will get.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Sorry, what would workbench.interface resolve to?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

An XML string

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ah, for the primary demo interface?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

for the code in the UI panel

@sonnyp sonnyp requested a review from andyholmes October 19, 2023 08:37
Copy link
Contributor

@andyholmes andyholmes left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM.

I expect with more use there will be some changes desired, but I like this overall.

@sonnyp sonnyp merged commit 8ee17a7 into main Oct 21, 2023
1 check passed
@sonnyp sonnyp deleted the sonnyp/workbench.build branch October 21, 2023 11:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Define Gtk closure expressions in code when the UI file is NOT a template.
2 participants