Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

revert emf model rebuild changes for layers view #187

Merged
merged 1 commit into from Feb 12, 2015
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
Expand Up @@ -105,21 +105,10 @@ public Adapter createContextModelAdapter() {
*/
@Override
public Adapter createLayerAdapter() {
if (layerItemProvider == null) {
layerItemProvider = new LayerItemProvider(this);
}

return layerItemProvider;
return new LayerItemProvider(this);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is an interesting change - I guess it makes a unique provider each time (rather than a single one). This is only necessary if the provider is now statefull - is that now the case?

}

/**
* This keeps track of the one adapter used for all {@link org.locationtech.udig.project.internal.Map} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected MapItemProvider mapItemProvider;


/**
* This creates an adapter for a {@link org.locationtech.udig.project.internal.Map}. <!--
* begin-user-doc --> <!-- end-user-doc -->
Expand All @@ -128,21 +117,9 @@ public Adapter createLayerAdapter() {
*/
@Override
public Adapter createMapAdapter() {
if (mapItemProvider == null) {
mapItemProvider = new MapItemProvider(this);
}

return mapItemProvider;
return new MapItemProvider(this);
}

/**
* This keeps track of the one adapter used for all {@link org.locationtech.udig.project.internal.Project} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected ProjectItemProvider projectItemProvider;

/**
* This creates an adapter for a {@link org.locationtech.udig.project.internal.Project}. <!--
* begin-user-doc --> <!-- end-user-doc -->
Expand All @@ -151,11 +128,7 @@ public Adapter createMapAdapter() {
*/
@Override
public Adapter createProjectAdapter() {
if (projectItemProvider == null) {
projectItemProvider = new ProjectItemProvider(this);
}

return projectItemProvider;
return new ProjectItemProvider(this);
}

/**
Expand Down Expand Up @@ -407,14 +380,6 @@ public Adapter createEditManagerAdapter() {
return editManagerItemProvider;
}

/**
* This keeps track of the one adapter used for all {@link org.locationtech.udig.project.internal.Layer} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
* @generated
*/
protected LayerItemProvider layerItemProvider;

/**
* This returns the root adapter factory that contains this factory.
* <!-- begin-user-doc -->
Expand Down Expand Up @@ -526,12 +491,6 @@ public void dispose() {
contextModelItemProvider.dispose();
if (editManagerItemProvider != null)
editManagerItemProvider.dispose();
if (layerItemProvider != null)
layerItemProvider.dispose();
if (mapItemProvider != null)
mapItemProvider.dispose();
if (projectItemProvider != null)
projectItemProvider.dispose();
if (projectRegistryItemProvider != null)
projectRegistryItemProvider.dispose();
if (styleBlackboardItemProvider != null)
Expand Down