1
0
Fork 0
mirror of https://github.com/geometer/FBReaderJ.git synced 2025-10-06 03:50:19 +02:00

code simplification

This commit is contained in:
Nikolay Pultsin 2013-10-08 02:28:08 +01:00
parent e9fa03ed9b
commit bb7f951387
3 changed files with 6 additions and 6 deletions

View file

@ -407,7 +407,7 @@ public class NetworkLibrary {
}
if (linkToTreeMap.isEmpty()) {
new SearchCatalogTree(myRootTree, mySearchItem, 0);
new SearchCatalogTree(myRootTree, mySearchItem);
new ManageCatalogsItemTree(myRootTree);
new AddCustomCatalogItemTree(myRootTree);
}

View file

@ -81,7 +81,7 @@ public class NetworkCatalogTree extends NetworkTree {
mySearchItem = new SingleCatalogSearchItem(link);
}
myChildrenItems.add(mySearchItem);
new SearchCatalogTree(this, mySearchItem, -1);
new SearchCatalogTree(this, mySearchItem);
}
}
}

View file

@ -25,13 +25,13 @@ import org.geometerplus.fbreader.network.NetworkLibrary;
import org.geometerplus.fbreader.network.SearchItem;
public class SearchCatalogTree extends NetworkCatalogTree {
public SearchCatalogTree(RootTree parent, SearchItem item, int position) {
super(parent, null, item, position);
public SearchCatalogTree(RootTree parent, SearchItem item) {
super(parent, null, item, -1);
item.setPattern(null);
}
public SearchCatalogTree(NetworkCatalogTree parent, SearchItem item, int position) {
super(parent, item, position);
public SearchCatalogTree(NetworkCatalogTree parent, SearchItem item) {
super(parent, item, -1);
item.setPattern(null);
}