Hello! This is my first time programming tcl so I barely know anything about how dialog boxes work in tk. Anyways, If I try to close the chat window while more than one tab is opened from the compiz-fusion scale addon (as in the expose mac os x-like feature in compiz-fusion), after the close dialog appears, an empty tk error dialog also appears with the following text as detail: "grab failed: another application has grab while executing "grab set $w" (procedure "::amsn::customMessageBox" line 106) invoked from within "::amsn::customMessageBox [trans closeall] yesnocancel question [trans title] $window 1 1 "ContainerClose"" (procedure "::ChatWindow::ContainerClose" line 18) invoked from within "::ChatWindow::ContainerClose .container_0" (command for "WM_DELETE_WINDOW" window manager protocol)" When that error dialog appears, the buttons on the close dialog no longer work and the only way I can close the chat window is to close each tab seperately until all the tabs have closed. In addition, now the close dialog that has appeared before isn't receiving any input and the only way to close it is to restart amsn or press the "esc" key while the close dialog is focused.
Since I know nothing of tk, I can only think of two solutions which are: 1. Create the close customMessageBox as a non-modal dialog. (Since I don't think creating it as a modal dialog is that necessary on account that it would be perfectly fine if all events are still available in the chat window while the dialog appears in my opinion) 2. In the function ::amsn::customMessageBox on line 835, add a catch statement around "grab set $w" Actually both those solutions aren't actually solutions, they're just workarounds. The first one doesn't even run the grab statement anymore since the if block it's in wouldn't be run. The second one is a workaround since even though the tk error messgae dialog isn't displayed anymore and everything seems to continue as normal (i.e.: All the buttons on the dialog work as they're supposed to), the chat window still allows events/inputs and therefore the dialog isn't actually a "real" modal dialog anymore. Honestly, I can't evaluate which would be the better solution for the reason that they're both just quick workarounds. Though, I think the second one would be better because in this case, the only drawback is that even though the close dialog will stay a modal dialog, when an error like this should have appeared, it would suppress it and the chat window would still be able to receive events, but as stated before, the close dialog actually does receive input and work as the user expects in comparison to if the error was not suppressed. Anyways, for the second workaround, I have proposed the patch for it if someone wants to test it. Again, I am pretty much illiterate in Tk, so if someone has a better idea or has a proper solution, please say it.
gui-grab-patch.patch
Description: Binary data
------------------------------------------------------------------------------ Check out the new SourceForge.net Marketplace. It is the best place to buy or sell services for just about anything Open Source. http://p.sf.net/sfu/Xq1LFB
_______________________________________________ Amsn-devel mailing list Amsn-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/amsn-devel