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

Accessibility: Add a context menu to scenes under project panel for scene variables #1505

Closed
triptych opened this issue Mar 7, 2020 · 19 comments · Fixed by #1607
Closed
Labels
👌good first issue Good issue if you want to start contributing to GDevelop

Comments

@triptych
Copy link
Contributor

triptych commented Mar 7, 2020

Describe the bug

Please see this thread:

https://forum.gdevelop-app.com/t/creating-editing-scene-variables-feature-request/23191

The ask is that when you right click on a scene from the Project view you see an "Edit Scene Properties" option.

Here's the context menu:
image

this is to make it consistent - just like the context menu under the Objects panel:

image

The popup you see is just the same as if you right-clicked on a blank space in the scene:

image

Note the "Edit Scene Variables" button there.

This would allow for the discovery of editing scene variables just like object variables and global variables.

@PawBud
Copy link
Contributor

PawBud commented Mar 8, 2020

I would like to work on this issue. Can you please guide me ?

@4ian
Copy link
Owner

4ian commented Mar 8, 2020

Look at ProjectManager/index.js and ScenePropertiesDialog.
Looks where ScenePropertiesDialog is used and how/if you should move its usage.

@4ian 4ian added the 👌good first issue Good issue if you want to start contributing to GDevelop label Mar 8, 2020
@PawBud
Copy link
Contributor

PawBud commented Mar 9, 2020

Understood @4ian. If I have any more issues then I will mention them here.

@PawBud
Copy link
Contributor

PawBud commented Mar 9, 2020

@4ian can you please elaborate more. I have been trying it for some time and I just need some help.
Thanks :)

@4ian
Copy link
Owner

4ian commented Mar 9, 2020

Have you located where ScenePropertiesDialog is used? Do you understand how it's opened?
If you used React before, do you have an idea about what to do? (if not, read some React tutorials before attempting anything ;)).

@PawBud
Copy link
Contributor

PawBud commented Mar 10, 2020

Sure thanks a lot for helping @4ian

@PawBud
Copy link
Contributor

PawBud commented Mar 11, 2020

I am aware of it @4ian it is just that somehow the index.js inside the MainFrame is showing errors as I try to resolve the errors in ProjectManager/Index.js

@PawBud
Copy link
Contributor

PawBud commented Mar 11, 2020

any idea how to resolve it? I can share the precise errors that I am getting while trying to import the ScenePropertiesDialog if needed :).

@jimil749
Copy link
Contributor

@4ian I was just tinkering with code and tried to implement the ScenePropertiesDialog like done in the SceneEditor/index.js and just found one minor issue. Inside of ProjectManager/index.js layout is not defined which is required by ScenePropertiesDialog.
I tried defining layout in props but of no use (Like done in SceneEditor/index.js). I tried to console log the layout props which yields 'undefined'. What I'm asking is that where is the 'layout' prop coming from and how to use it.

@PawBud
Copy link
Contributor

PawBud commented Mar 11, 2020

well, technically it is defined as

layout: glayout.

@PawBud
Copy link
Contributor

PawBud commented Mar 11, 2020

Moreover, how were you able to add it in the Properties menu @jimil749?

@jimil749
Copy link
Contributor

jimil749 commented Mar 11, 2020

well, technically it is defined as

layout: glayout.

I think its gdLayout, but even after doing that, it logs undefined on the console! The value into layout prop is undefined for some reason, that I'm not able to figure out currently

Moreover, how were you able to add it in the Properties menu @jimil749?

Look at `ProjectManger/index.js' and check where the other menu items are rendered! :)

@PawBud
Copy link
Contributor

PawBud commented Mar 12, 2020

I definitely tried everything but I couldn't really make the Scene Properties Dialog run for some reason, although I will keep trying.

@PawBud
Copy link
Contributor

PawBud commented Mar 16, 2020

@4ian I tried my best to solve this bug but unfortunately, I couldn't come up with a solution, although I am still willing to work on this bug since I want to contribute to this organization as much as I can so, Can you further guide me?

@4ian
Copy link
Owner

4ian commented Mar 16, 2020

I have lots of other things to review and to do myself in a limited time every day so I would prefer a suggestion from you that I can then advise.
Here, you need to identify which React components must be opened, identify where to open them, what are the props they need and how to pass them. It's a good exercice that is fairly common in React: finding components and props, understanding what they do, seeing what you have in your state.

@PawBud
Copy link
Contributor

PawBud commented Mar 17, 2020

Oh ok sure, yea .. is it ok if I post some screenshots explaining what I am trying to do & what its output is?

@4ian
Copy link
Owner

4ian commented Mar 17, 2020

You can ask questions but do this in a PR so that I can see your code and ask questions as focused as possible :)

@PawBud
Copy link
Contributor

PawBud commented Mar 17, 2020

Thanks a lot. I will post the screenshots in a new PR as you advised.

@nilaymaj
Copy link
Contributor

@Somtozech Are you still working on this issue? I want to try this one.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
👌good first issue Good issue if you want to start contributing to GDevelop
Projects
None yet
5 participants