Recent

Author Topic: Problem with Alt + Tab between Forms  (Read 5687 times)

Stefano

  • New Member
  • *
  • Posts: 39
Problem with Alt + Tab between Forms
« on: September 04, 2012, 10:36:01 pm »
Hello,

Since version 0.9.30 of Lazarus I find problems at run-time deplacing from the forms of a project with Alt + Tab, if there are data-aware controls.

If I move from one form to another and then back on the form of departure:
-If I was on a DBEdit, the latest changes are lost (but here I could solve with a Post in the Deactivate event);
-If I go on a DBGrid there are big problems to enter the data in the cells, usually I can insert data the first time in a cell, but when I leave the cell, the cell no longer has the red border and each character replaces the previous one, so it is difficult to write text.

Initially I thought it was a bug in the DBGrid, because with version 0.9.30 there were some problems with the DBGrid, and I segnaled the bug along with the other problems of the DBGrid:
http://bugs.freepascal.org/view.php?id=19993

Now I noticed that the problem concerns the fact of moving with Alt + Tab and affects all data-aware components, even if the problem is major with the DBGrid, and I opened the problem in a specific way:
http://bugs.freepascal.org/view.php?id=22475

Unfortunately I have not yet received a response and I do not know if and when the problem will be corrected.

The problem seems to occur on the Activate event, that means when I go on a form with Alt + Tab:

-If I move between the forms/windows with the mouse on the TaskBar there are no problems;
-If I move between the forms/windows by code it works well;
-If I move from one form to another with the TaskBar and back with Alt + Tab the problem occurs;
-If I move from one form to another with Alt + Tab and return the TaskBar with the problem does not occur.

I use Linux (Debian, Squeeze) with GTK2.

All the versions 0.9.30, 0.9.30.2, 0.9.30.4, and the new 1.0 of Lazarus have the same problem, which forces me to stay still at version 0.9.28.2 which works very well, but now is old.

I do not know what to do to solve, I would try to bypass the problem in order to be able to use Lazarus 1.0. Unfortunately, this problem is too serious, I have a complex project with dozens of forms in which the user moves continuously.

Has anyone else encountered the same problem?

Do you have any advice in order to bypass the problem and make use of the latest versions of Lazarus?

Thanks very much for any help.

Sorry for my bad English.

Stefano
Stefano Cortelli
Studio Rag. Cortelli
(Preferred languages: Italiano / Deutsch / Français)

Knipfty

  • Full Member
  • ***
  • Posts: 232
Re: Problem with Alt + Tab between Forms
« Reply #1 on: September 04, 2012, 10:39:08 pm »
Hi Stefano,

Could you post a sample project that demonstrates the above behavior?   IT would make it easier for others to test and seeing the code is always a good thing.

Thanks

Knipfty
64-bit Lazarus 2.2.0 FPC 3.2.2, 64-bit Win 11

Stefano

  • New Member
  • *
  • Posts: 39
Re: Problem with Alt + Tab between Forms
« Reply #2 on: September 05, 2012, 03:29:06 pm »
Hallo Knipfty,

I join a sample project. The project uses a Firebird database. I've made a unit that uses SQLDb, another unit that uses UIB and FBDataset. You can choose the unit you prefer.

You need to set your path to the Firebird DB. The Firebird database is attached also in FBK (Backup) Format, and also as FDB file.

In the begin of the main form I've explained better the problem.

Thank you very much for any Help.

Best regards,

Stefano
Stefano Cortelli
Studio Rag. Cortelli
(Preferred languages: Italiano / Deutsch / Français)

Knipfty

  • Full Member
  • ***
  • Posts: 232
Re: Problem with Alt + Tab between Forms
« Reply #3 on: September 05, 2012, 03:53:40 pm »
Hello Stefano,

I'm doing a little traveling right now and probably won't get a chance to look at this until the weekend.

Knipfty
64-bit Lazarus 2.2.0 FPC 3.2.2, 64-bit Win 11

Stefano

  • New Member
  • *
  • Posts: 39
Re: Problem with Alt + Tab between Forms
« Reply #4 on: September 05, 2012, 06:10:57 pm »
Thank you Knipfty, don't worry, I can wait the week-end.

Meanwhile I've uploaded the Test Project auch in the Bugtracker:
http://bugs.freepascal.org/view.php?id=22475
and added the bug of the DbGrid that lost focus:
http://bugs.freepascal.org/view.php?id=22804

Thank you very much if you can help me.

Best regards,

Stefano


Stefano Cortelli
Studio Rag. Cortelli
(Preferred languages: Italiano / Deutsch / Français)

 

TinyPortal © 2005-2018