can a dojo dialog bring up another dojo dialog?
dojo 1.3 only supports one modal dialog at a time, so while, yes, one dialog can open another, closing the second destroys the modality of the first.
This happens because dojo.Dialog uses a single global underlay object that provides screen between the dialog and anything else on the page. You can make it work if you're wiling to create your own underlay for each dialog and manage the z-indexes yourself.
I understand this will be rectified in 1.4.
Yes, a dialog can open another dialog, but then you'd have two dialogs displayed -- they aren't modal between each other.
Since this is not the behavior I desire I've worked around this by creating my own handler -- it first checks for an open dialog, and if it finds one, closes it (and places it on a stack) before opening a new dialog. When it closes one it looks at the stack and re-opens dialogs lower on the stack.
Multiple dialogs can be opened prior to Dojo 1.4, but there are problems with accessibility in that case (tabIndex is handled wrong) - so if you need your app to be accessible and support mutliple dialogs., you need to upgrade to Dojo 1.4 when it comes out.
yes you are able to do it in dojo 1.6 and all above versions
Related
I am writing a simple application in python using PyGObject and glade. The application has a main window and a functional window (Generate logs, also a Window object) which opens up on clicking a menu item.
The Generate logs window is supposed to:
Show options to generate log for a particular date
Be minimizable and should close automatically when the task is complete (OR)
Be able to be closed manually if the user wishes so
The problem is, once I show up the Generate logs window, I am directly able to select the main window as well. Then, I can go to the menu and bring up as many Generate logs windows as I want.
I have tried several options (Is Focus, setting up main window as Transient parent etc) but nothing worked. How can I fix this?
First you say PyGTK, then you say PyGObject, this are 2 different things. I'm going to answer for PyGTK (my sources are from GTK+ 2 docs) since it's in the title and maybe people looking for that will end up here. But never fear, because for this question, the answer is practically (I think exactly) the same for both.
What I understand is that you want you "Generate log" window to be modal. That means other windows can't be used while your modal window is up, just like a Dialog window. Also you should set the main window to be the parent of your modal window, since this helps the OS Window Manager i.e. keep the dialog on top of the main window.
Yo can do both of this things directly from Glade (if you've created both windows in the same project, not always the case) selecting the Modal atribute to True and the Transient for Window attribute to your main window, in the General Properties section of your Generate log window.
Also you can do it programmatically using the set_modal() and the set_transient_for(parent_window) method of your child window.
Let's say your parent window is called main_window and the child window is generate_log_window, then you can do it like this:
generate_log_window.set_modal(gtk.TRUE)
generate_log_window.set_transient_for(main_window)
If you want it to show center top of your main window, do this
generate_log_window.set_position(gtk.WIN_POS_CENTER_ON_PARENT)
To your second point, the ability to minimize can be set from Glade.
Sources:
GTK+ 2 GtkWindow reference set_modal
GTK+ 2 GtkWindow reference set_transient_for
PyGTK FAQ: How do I get my windows to show up where I want
PyGTK FAQ: How do I make a dialog block the whole application, so the user is forced to answer it?
create several windows (see your other post).
Upload them in init
Show them with "signals" in glade using "show" and "hide"
class GUIxxxx
#...
def action1(self, widget, data=None):
self.window1.show()
def action2(self, widget, data=None):
# do something here
self.window1.hide()
For example Version Control tool window. I never use it. I use version control support, but not this tool window itself. How can I remove it from tool window bar?
I've found a plugin to hide certain tool windows
https://plugins.jetbrains.com/plugin/?id=1489
If you don't need to actually hide the button, but just don't want it in the way while looking for the buttons you do use regularly, you can always drag it to some side of the screen that you don't often use. (I rarely use the bottom-right, so I could move some things there.) That way, you don't see them when picking a tab, but you can still get to it if you need to. (And every once in a while, I suspect you may really want to look at that Version Control view.)
Having upgraded jqModal from r13 to r22, I find that where my dialogs contain text inputs it is not possible to type into them. Removing modal:true from the settings fixes it, but I don't want my users to be able to dismiss the dialog by clicking on the overlay. Is this behaviour by design, or is it a bug?
This is certainly not by design. I have released a fix (+r23). Please open a github issue if you require further assistance.
Related:
If you're nesting modals, be sure to have a higher z-index value on child modals.
You may override the $.jqm.focusFunc() to provide custom behaviour for events occurring outside the currently active modal.
I'm a frontend developer and I have a multi-monitor setup. I have HTML code on one monitor and CSS code on another monitor.
To achieve that, I drag a tab out of IntelliJ IDEA window, so that the tab opens in a separate window.
My problem is that the secondary window lacks a menu:
Menu access hot keys (e.g. Alt+V) won't work. I can't make use of the main window's menu either because when I click it, the focus switches to the active tab of the main window.
How do I access the menu when I'm working in IDEA's secondary window?
This feature is currently not available in IntelliJ IDEA.
The alternatives I could think of to do what you want:
Consider raising a feature request on http://youtrack.jetbrains.com/
Do you think it's possible that you might not miss the menu on the detached tab if instead of accessing functionality through the menu, you did the same through keyboard shortcuts?
Personally, being a keyboard junkie, I have not felt the lack of a menu on the detached tab.
Even though Eclipse allows you to create a new window for the same workspace, I had some issues with it ( for eg: if you set a breakpoint in a file in Window 1, and started a debug session from Window 2, then the file would be re-opened in Window 2 when the breakpoint is hit) and feel that the Intellij IDEA implementation works better.
(Warning! The most Hacky suggestion) Assuming you are using Windows, there are a number of ways in which you could extend the single IntelliJ window across the two monitors and then instead of detaching a tab, you could do a 'Split Vertically' in that single window. With the slider between the tabs positioned just right, it will seem you have two windows opened with each of them having a menu.
To extend a window across two monitors see : How can you maximize a window on to dual monitors in Windows 7 or use one of the multi-monitor tools listed here or here ( I vaguely recall that it was the latter 'zbar' that I used to extend a window during my eclipse days).
Believe it or not, I have done this with Eclipse when I was sick of guessing where the file-with-the-breakpoint would open up :)
In a progress dialog (IProgressMonitor), there is a Details button that expands the progress dialog to show the details section. How do I open the details section programmatically in my Eclipse plugin?
Thanks.
You don't.
The UI for progress reporting is absolutely not part of the progress API, instead only the concept of tasks, sub tasks and their running state is part of that API. So in another version of eclipse the progress might be shown by playing a sound instead of showing a dialog.
Even your assumption of having that dialog is wrong. When you activate the workspace preference "Always in background", then a user will not see that dialog at all.
And as a last thing: Even if you feel that your plugin is so important that it should behave different than other plugins in Eclipse (and therefore want to access that progress dialog somehow), your users will not feel the same. And they will be confused when installing your plugin together with other plugins because they don't behave the same, although being part of one installation.