View Issue Details
ID | Project | Category | View Status | Date Submitted | Last Update |
---|---|---|---|---|---|
0003043 | JEDI VCL | 00 JVCL Components | public | 2005-06-17 18:33 | 2005-06-20 00:47 |
Reporter | vlador | Assigned To | obones | ||
Priority | normal | Severity | major | Reproducibility | always |
Status | resolved | Resolution | no change required | ||
Product Version | 3.00 | ||||
Target Version | Fixed in Version | ||||
Summary | 0003043: JvTabBar - tab won't close when using OnTabClosing event | ||||
Description | If we ask user something like "Are you sure you want to close?" in the OnTabClosing event, the tab will not close no matter what user selects. | ||||
Additional Information | This is easy to reproduce: 1. Put a JvTabBar on the form 2. Create few tabs 3. Define OnTabClosing like this: procedure TForm1.JvTabBar1TabClosing(...); begin AllowClose := True; ShowMessage('Tab will not close!'); end; 4. Run application and try to click at tab's close button. I tried to find a reason for this and it seems that, if some other window pops up, MouseUp message is never sent. | ||||
Tags | No tags attached. | ||||
|
OnTabClosing's symatic is to prevent the "close button" to be painted pressed and not to show a "can close?" dialog. If you want a "can close?" confirmation dialog you should set TabBar.AutoFreeClosed:=False and write in the OnTabClosed event something like this: if MessageDlg('Do you want to close the tab?', mtConfirmation, [mbYes, mbNo], 0) = mrYes then Item.Free; // close the button If you use AutoFreeClosed then you are not able to show a confirmation dialog because then JvTabBar is resposible for tab closing/destroying. |
|
Thanks... I didn't realize this... |
|
Well then, I'm considering this to be ok. |
Date Modified | Username | Field | Change |
---|---|---|---|
2005-06-17 18:33 | vlador | New Issue | |
2005-06-18 05:20 | AHUser | Note Added: 0007480 | |
2005-06-18 05:26 | AHUser | Status | new => feedback |
2005-06-19 13:26 | anonymous | Note Added: 0007482 | |
2005-06-19 14:07 | anonymous | Note Edited: 0007482 | |
2005-06-20 00:47 | obones | Status | feedback => resolved |
2005-06-20 00:47 | obones | Resolution | open => no change required |
2005-06-20 00:47 | obones | Assigned To | => obones |
2005-06-20 00:47 | obones | Note Added: 0007483 |