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

Toolbar enhancement request - Open #1432

Open
tlhackque opened this issue Jun 17, 2018 · 7 comments
Open

Toolbar enhancement request - Open #1432

tlhackque opened this issue Jun 17, 2018 · 7 comments
Assignees
Labels
enhancement Feature requests.

Comments

@tlhackque
Copy link

Describe the new feature

The icons on the tool bar are handy - I often open and close a database as the "real" application evolves.

I would like an 'open database Read-only' icon - or perhaps the open database icon could have two faces, one for Open and one for Open RO. (I think this is called a "split button") In this case, the default would be Open (read/write) initially, with RO on the dropdown. if I open RO, the default would be to open ro again.

This would be very convenient for repeatedly opening a db read-only.

Additional info

Please answer these questions before submitting your feature request.

Is your feature request related to an issue? Please include the issue number.

No

Does this feature exist in another product or project? Please provide a link.

Don't know

Do you have a screenshot? Please add screenshots to help explain your idea.

No.

@justinclift justinclift added the enhancement Feature requests. label Jun 17, 2018
@justinclift
Copy link
Member

Good thinking @tlhackque, sounds like a decent idea. 😄

@mgrojo mgrojo self-assigned this Jun 24, 2018
mgrojo added a commit that referenced this issue Jun 24, 2018
A popup menu has been added in the "Open Database" button. A normal click
selects the "Open Database..." action as before. A delayed click opens the
popup menu for selecting either the "Open Database..." action or the
"Open Database Read Only..." action.
@justinclift
Copy link
Member

@mgrojo Just noticed your commit. Is it ready to test? 😄

@mgrojo
Copy link
Member

mgrojo commented Jun 25, 2018 via email

@justinclift
Copy link
Member

@tlhackque When you have a few moments, would you be ok to try out the new latest nightly build and see if the new pop-up menu for Open-ing works?

Initial description from the commit contents:

A popup menu has been added in the "Open Database" button. A normal click selects the "Open Database..." action as before. A delayed click opens the popup menu for selecting either the "Open Database..." action or the "Open Database Read Only..." action.

@tlhackque
Copy link
Author

Well, that's different.

Usually a split button has two active areas; click on the big area, you get the default selection; click on the small you get options. Without the clue here, I would not have guessed how it worked.

I found a picture of a standard Split button - actually from a control that shows how they are setup. It's a bit dated, but accurate

image

This one opens the split if you press and hold. I can get used to it, but it's not usual.

Also, if I open a database RO, and close it. the default on the button remains R/W. I'd hoped the default action would change to the latest selection - if i open RO once, the next time I'm likely to to do the same. See the "persist dropdown name" option on the panel.

That said, it's an improvement over wandering over to File, so if your toolkit doesn't support standard split buttons, I'll gladly take the forward motion!

thanks for the effort, @mgrojo .

@mgrojo
Copy link
Member

mgrojo commented Jun 25, 2018

That's right, Qt doesn't support standard split buttons. I reused the pattern already present in the "Save SQL" button in the "Execute SQL" toolbar.

This is the most far that we can reach without overcomplicating the code for the button.

By the way, if your pattern for closing and reopening it again in RO is just for updating a DB modified outside the application, the most direct way is to press F5 or click on the Refresh button of the Browse Data tab. You don't actually need to close the DB.

@tlhackque
Copy link
Author

You don't actually need to close the DB.

Actually, I do. the case I ran into was where I wanted to delete the database and reload it - as i was enhancing the loader & doing some performance work. i can't delete it if the browser has it open.

I use refresh a lot.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement Feature requests.
Projects
None yet
Development

No branches or pull requests

3 participants