diff options
author | YAMAZAKI Makoto <makoto1975@gmail.com> | 2012-03-03 20:05:57 +0900 |
---|---|---|
committer | YAMAZAKI Makoto <makoto1975@gmail.com> | 2012-03-03 20:05:57 +0900 |
commit | e49f6111a67ef1ae92bfc2bc2a78e2f69456a1aa (patch) | |
tree | 97258da8ef7d6217cb9f90263708e37da9141da9 /eclipse | |
parent | b896b23cfdb2973837b2c24bfff56a094556025c (diff) | |
download | sdk-e49f6111a67ef1ae92bfc2bc2a78e2f69456a1aa.zip sdk-e49f6111a67ef1ae92bfc2bc2a78e2f69456a1aa.tar.gz sdk-e49f6111a67ef1ae92bfc2bc2a78e2f69456a1aa.tar.bz2 |
fixes a bug that Working Set specified in "New Android Project" wizard is ignored in some cases.
In original code, specified Working Set data is set to mValues in ProjectNamePage#canFlipToNextPage(). This hack works in some cases, but not always.
canFlipToNextPage is invoked when user changes the name of project, but is not invoked when user changed the data of Working Set. So, if user changes WorkingSet as last action of this page, it is ignored.
I moved "mValues.workingSets = getWorkingSets();" from canFlipToNextPage() to getNextPage() because getNextPage() is alwasys invoked at the end of ProjectNamePage.
http://code.google.com/p/android/issues/detail?id=21508
Change-Id: I336fe449703144ac7a053cce6a946f931e97bb9f
Signed-off-by: YAMAZAKI Makoto <makoto1975@gmail.com>
Diffstat (limited to 'eclipse')
-rw-r--r-- | eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/wizards/newproject/ProjectNamePage.java | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/wizards/newproject/ProjectNamePage.java b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/wizards/newproject/ProjectNamePage.java index ff77b9f..d4c342c 100644 --- a/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/wizards/newproject/ProjectNamePage.java +++ b/eclipse/plugins/com.android.ide.eclipse.adt/src/com/android/ide/eclipse/adt/internal/wizards/newproject/ProjectNamePage.java @@ -40,6 +40,7 @@ import org.eclipse.core.runtime.Platform; import org.eclipse.core.runtime.Status; import org.eclipse.jface.dialogs.IMessageProvider; import org.eclipse.jface.viewers.IStructuredSelection; +import org.eclipse.jface.wizard.IWizardPage; import org.eclipse.jface.wizard.WizardPage; import org.eclipse.osgi.util.TextProcessor; import org.eclipse.swt.SWT; @@ -625,11 +626,11 @@ class ProjectNamePage extends WizardPage implements SelectionListener, ModifyLis } @Override - public boolean canFlipToNextPage() { + public IWizardPage getNextPage() { // Sync working set data to the value object, since the WorkingSetGroup // doesn't let us add listeners to do this lazily mValues.workingSets = getWorkingSets(); - return super.canFlipToNextPage(); + return super.getNextPage(); } } |