sugarlabs / Bridge

Bridge Sugar activity
GNU General Public License v3.0
2 stars 17 forks source link

Made the toolbar show the currently selected tool #33

Closed marsian83 closed 1 year ago

marsian83 commented 1 year ago

Overview

I have turned the toolbar buttons at the top of the activity so that we know what toolbar item has been selected

Description

I have changed the ToolButtons to RadioToolButtons

Screenshots

Screenshot_20230215_055928

Before changes: The screenshot shows the grab tool being selected but there is no indication as to it being selected

WhatsApp Image 2023-02-15 at 17 53 20

After the changes : In the above screenshot the Grab tool is selected and is shown clearly

quozl commented 1 year ago

No, thank you. This is a substantial change to the user interface design that would make this activity very different from all the others and the Sugar shell.

It is however an interesting use of the radio button class I wasn't aware of. :grin:

marsian83 commented 1 year ago

Hi @quozl, I have applied the same logic as I witnessed in physics activity this line of code in the physics activity is where I saw the same logic being employed

Also, I do not understand how these are not mutually exclusive I have only added the [Circle, Girder, Grab, Destroy, Bridge Joint] tools as RadioToolButtons and the pause, create train and restart buttons function the same and are separate from the RadioButtons as shown in the screenshot attached

Screenshot_20230216_013724

Above screenshot shows the two buttons being activated separately, one indicating that the circle tool has been selected and the other one indicating that the game is resumes

I was also wondering if RadioToolButtons are not to be used in this case, shall I change the ones used in physics activity as well?

quozl commented 1 year ago

Okay, thanks.

Your commit message was too brief. Please put all details about the change into the commit message prior to making the pull request. See https://github.com/sugarlabs/sugar-docs/blob/master/src/contributing.md#making-commits

In Physics the toolbars are in submenus, so the nature and extent is clear. Please add some separator between the radio button array and the other buttons.

Tested.

marsian83 commented 1 year ago

Hi @quozl I have added separators in the toolbar Now the RadioButtons appear visually detached as shown in the below screenshot

image
quozl commented 1 year ago

Again, your commit messages are weak. Remember pull requests are not retained, only the commit messages are retained in the git history.