View Issue Details

IDProjectCategoryView StatusLast Update
0018910LazarusLCLpublic2014-04-11 20:32
ReporterBenito van der Zander Assigned ToZeljan Rikalo  
PrioritynormalSeverityminorReproducibilityalways
Status closedResolutionfixed 
Platformamd64OSDebian 
Product Version0.9.31 (SVN) 
Summary0018910: qt don't want to close
DescriptionIf you have a (empty) qt form running and shutdown your computer, gnome shows a message "<project> doesn't react"

The project is simply closed with gtk2
Tagsqt bindings
Fixed in Revision43043
LazTarget1.2
WidgetsetQT
Attached Files

Relationships

related to 0020920 resolvedG. Colla form.onclosequery not activated on Linux OS shutdown 

Activities

Zeljan Rikalo

2011-03-12 09:36

developer   ~0046564

Last edited: 2011-03-14 12:34

Look like we need QSessionManager in our bindings.
http://doc.qt.nokia.com/stable/session.html
But that implies new class QLCLApplication (*maybe* because commitData() and saveState() should be overriden), on the other hand we don't have
QApplication::commitDataRequest and QApplication::saveStateRequest signals inside bindings, which probably could resolve our problem even without QSessionManager and without QLCLApplication introduction.
UPDATE: if we have just QApplication::commitDataRequest we can call something like:
  if not Application.Terminated then
    CreateAnLCLQtEventToTerminateApp() // must be so to avoid crash if we call APplication.Terminate directly here.
Also check for Application.Terminated is needed because this signal is triggered always - when we terminate our app or when WM tries to terminate it.

Zeljan Rikalo

2011-07-03 17:05

developer   ~0049622

hm..maybe adding QuitOnClose attribute to main form can fix this.

Zeljan Rikalo

2011-07-04 18:00

developer   ~0049656

No, QuitOnClose is evil for lcl.

Zeljan Rikalo

2012-02-06 17:57

developer   ~0056586

Postponed to 1.2 since this is not connected to qt's session management.
I've already tried to implement it but nothing helps with gnome, other window managers works fine. So, it will be implemented together with gtk2 session management.

Zeljan Rikalo

2013-09-30 13:14

developer   ~0070451

Please test and close if ok.
IMPORTANT NOTE: if you do not cancel session shutdown (so eg you can logout without interacting) then some older gnome session managers need few seconds before logot continues. Under eg new gnome (fedora 18) it proceeds to logout.
If you decide to cancel logout/reboot you can do that.
I've used Application.OnQueryEndSession to test this.

Zeljan Rikalo

2014-04-11 20:32

developer   ~0074326

IMO, 6 months is enough to test and close or give feedback, so closing.

Issue History

Date Modified Username Field Change
2011-03-11 13:43 Benito van der Zander New Issue
2011-03-11 13:43 Benito van der Zander Widgetset => QT
2011-03-11 15:34 Zeljan Rikalo Status new => assigned
2011-03-11 15:34 Zeljan Rikalo Assigned To => Zeljan Rikalo
2011-03-12 09:36 Zeljan Rikalo Note Added: 0046564
2011-03-12 09:42 Zeljan Rikalo LazTarget => 1.0
2011-03-14 12:34 Zeljan Rikalo Note Edited: 0046564
2011-06-08 20:22 Zeljan Rikalo Tag Attached: qt bindings
2011-07-03 17:05 Zeljan Rikalo Note Added: 0049622
2011-07-04 18:00 Zeljan Rikalo Note Added: 0049656
2011-12-17 20:46 Zeljan Rikalo Relationship added related to 0020921
2011-12-17 20:46 Zeljan Rikalo Relationship added related to 0020920
2011-12-17 20:47 Zeljan Rikalo Relationship deleted related to 0020921
2012-02-06 17:57 Zeljan Rikalo LazTarget 1.0 => 1.2
2012-02-06 17:57 Zeljan Rikalo Note Added: 0056586
2013-09-30 13:14 Zeljan Rikalo Fixed in Revision => 43043
2013-09-30 13:14 Zeljan Rikalo Note Added: 0070451
2013-09-30 13:14 Zeljan Rikalo Status assigned => resolved
2013-09-30 13:14 Zeljan Rikalo Resolution open => fixed
2014-04-11 20:32 Zeljan Rikalo Note Added: 0074326
2014-04-11 20:32 Zeljan Rikalo Status resolved => closed