Git Product home page Git Product logo

Comments (12)

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
Hi thunor,

With the new development to fix this issue:

Are you still going to support the use of a launched dialog´s variable to be 
passed?.  For backward compatibility with programs already written to work like 
it.

Or a total functional rewrite is needed then breaking backward compatibility?

Regards,
clarf

Original comment by [email protected] on 28 Jul 2011 at 4:19

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
Hi clarf :)

Currently any variable from the launched dialog can be passed to closewindow, 
so I'm not going to change that functionality since everyone is using it. I 
will simply (or that's the plan) add an additional correct way to close the 
launched dialog.

Regards,
Thunor

Original comment by [email protected] on 28 Jul 2011 at 9:24

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
I'm working on something at the moment whereby I launch a dialog from a timer. 
it works the first time and then the timer stops functioning so it looks as 
though launching a dialog kills the timer. This would make sense since I have 
seen that launching requires exiting GTK+'s main loop and the GTK+ timer 
creation function apparently uses the main loop for timing.

I haven't investigated it yet; I just wanted to note it.

Original comment by [email protected] on 18 Nov 2011 at 1:54

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
The example I've given towards the top is wrong: it is supposed to be called 
without window tags i.e. it uses the second format of the window widget which 
is with the directives at the top and without window tags. I don't know why 
there's a second format -- maybe it was exclusively to support launched 
dialogs. Then the dialog works as expected (only one window will be opened) but 
then you can't use window tag attributes! The way around that is to use the 
window tag but maintain a value in a file that records the dialog launching and 
closing so you can check before launching another. There are benefits to using 
launch such as being able to refresh its widgets from the main dialog, but the 
system is messy and needs some attention.

Original comment by [email protected] on 18 Nov 2011 at 2:39

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
I discovered last night that a launch action terminates the list of actions so 
that any actions following it don't get executed. This also affects any 
triggering action e.g. a widget's action sets a value in a file and then the 
next action refreshes a target widget which reads this file and that triggers 
the target widget's default signal and one of the target widget's actions 
executes launch which terminates all further actions.

Original comment by [email protected] on 20 Nov 2011 at 10:27

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
Hello, is here any solution about this bug?
I downgrade to 0.7.20, because i wrote some scripts with 
      <button>
        <label>OK</label>
          <action type="closewindow">ABOUT</action>
      </button>
and if i click on OK, it will not closing in current version.

Thanks in advance
Daniel aka leiche 

Original comment by [email protected] on 16 Jul 2012 at 5:49

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
Hi Daniel

It does work, it's just that the way it has been implemented is problematic. 
Anyway, 0.8.0 has had a patch applied that fixes the even worse behaviour in 
0.7.20 so you shouldn't downgrade. Also there are working examples in the 
source package which you should look at, and I can't tell from your snippet of 
code why it fails to work. I'm guessing that your main window is using the 
<window> tag which you shouldn't have if you are planning on launching another 
window from it.

Regards,
Thunor

Original comment by [email protected] on 27 Jul 2012 at 11:33

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
In r326 I've gone through the launch and closewindow functions and added some 
code to display a warning if a launched window does not contain an equivalently 
named variable so that application developers will know if they've got it wrong.

I've added a new example example/miscellaneous/launch_and_closewindow which you 
should take a look at.

http://gtkdialog.googlecode.com/svn/trunk/examples/miscellaneous/launch_and_clos
ewindow

Regards,
Thunor


Original comment by [email protected] on 2 Aug 2012 at 4:44

  • Changed state: Fixed

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
I've experienced another problem although it's more a design limitation: 
attempting to launch a window from an <action 
signal="show">launch:mynewwindow</action> attached to the main window will 
cause an error coming from the parser making you think it's related to the main 
window, but the problem actually lies with parsing a program when one is 
already being parsed. After hours of debugging I found the line that causes 
this error -- automaton.c:515 gtk_widget_show_all() -- and it's pretty obvious 
now what the issue is: the run_program() function can only parse one program at 
a time i.e. it's not reentrant; in fact run_program() doesn't even return as it 
calls gtk_main().

I've just dealt with this by refusing to launch if instruction_counter != 0 
with a warning message sent to stderr.

Original comment by [email protected] on 28 Aug 2012 at 3:27

  • Changed state: New

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
What's remaining here then is the timer problem which I might be able to do 
something about; I'll come back to this.

Original comment by [email protected] on 29 Aug 2012 at 12:31

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024

Original comment by [email protected] on 5 Sep 2012 at 4:34

  • Added labels: Priority-High
  • Removed labels: Priority-Medium

from gtkdialog.

GoogleCodeExporter avatar GoogleCodeExporter commented on June 24, 2024
Fixed in r416.

The problem with the timer was quite simple: launching is a one way trip i.e. 
it doesn't return so doing it in a timer callback never returns to the callback 
-- I have added a check for this and a warning is dumped to the terminal. The 
solution is to get the timer to activate another widget that launches so that 
it's done outside of the callback.

There are no remaining issues with launch and closewindow so this is fixed.

Original comment by [email protected] on 8 Sep 2012 at 12:37

  • Changed state: Fixed

from gtkdialog.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.