This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 252874 - An Options Dialog that is modal does not call applyChanges method
Summary: An Options Dialog that is modal does not call applyChanges method
Status: RESOLVED FIXED
Alias: None
Product: platform
Classification: Unclassified
Component: Options&Settings (show other bugs)
Version: 8.0.2
Hardware: PC Windows 7 x64
: P1 normal (vote)
Assignee: Theofanis Oikonomou
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2015-06-08 13:48 UTC by glenn_david
Modified: 2015-07-17 01:18 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description glenn_david 2015-06-08 13:48:15 UTC
When the Options Dialog is opened using:      

import org.netbeans.api.options.OptionsDisplayer;

OptionsDisplayer.getDefault().open("id", true);


The custom application Options Dialog is opened as a modal dialog as expected but
it results in a the OptionsPanelController method applyChanges() to not be called when either the "Apply" or "OK" button is pressed.

When the following call is made instead:

OptionsDisplayer.getDefault().open("id", false);

The custom application Options Dialog is opened as a non-modal dialog as expected
and the OptionsPanelController method applyChanges() is called when the "Apply" or "OK" button is pressed.


P.S. Is it possible to hide/remove the "Apply" button?
Comment 1 Theofanis Oikonomou 2015-07-08 10:16:02 UTC
Changeset: 9812875354af
Author:    Theofanis Oikonomou <theofanis@netbeans.org>
Date:      2015-07-08 13:14
Message:
Comment 2 Theofanis Oikonomou 2015-07-08 10:19:43 UTC
The problem was not that applyChanges() was not called. There was some weird NbPresenter issue. I tried to work around it and now it seems to work as expected. At least for my dummy options panel and dummy action that opens it as modal dialog. Please try a latest build and reopen if it still does not work for you. Thank you
Comment 3 Quality Engineering 2015-07-17 01:18:32 UTC
Integrated into 'main-silver', will be available in build *201507170001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)

Changeset: http://hg.netbeans.org/main-silver/rev/9812875354af
User: Theofanis Oikonomou <theofanis@netbeans.org>
Log: Task #252874 - An Options Dialog that is modal does not call applyChanges method