Revision 41264 trunk/org.gvsig.desktop/org.gvsig.desktop.plugin/org.gvsig.app/org.gvsig.app.mainplugin/src/main/java/org/gvsig/app/imp/DefaultAppgvSIGManager.java
DefaultAppgvSIGManager.java | ||
---|---|---|
29 | 29 |
import java.util.ArrayList; |
30 | 30 |
import java.util.Iterator; |
31 | 31 |
import java.util.List; |
32 |
import javax.swing.JComponent; |
|
32 | 33 |
|
33 | 34 |
import javax.swing.JFileChooser; |
34 | 35 |
import javax.swing.filechooser.FileFilter; |
... | ... | |
56 | 57 |
import org.gvsig.app.project.ProjectManager; |
57 | 58 |
import org.gvsig.app.project.documents.Document; |
58 | 59 |
import org.gvsig.app.project.documents.gui.IDocumentWindow; |
60 |
import org.gvsig.app.project.documents.view.ViewDocument; |
|
59 | 61 |
import org.gvsig.fmap.crs.CRSFactory; |
60 | 62 |
import org.gvsig.fmap.dal.DALLocator; |
61 | 63 |
import org.gvsig.fmap.dal.DataManager; |
... | ... | |
397 | 399 |
} |
398 | 400 |
return project.getActiveDocument(documentClass); |
399 | 401 |
} |
402 |
|
|
403 |
public JComponent getActiveComponent(Class<? extends Document> documentClass) { |
|
404 |
Document document = this.getActiveDocument(documentClass); |
|
405 |
if (document == null) { |
|
406 |
return null; |
|
407 |
} |
|
408 |
return document.getMainComponent(); |
|
409 |
} |
|
400 | 410 |
|
411 |
|
|
401 | 412 |
public IDocumentWindow getDocumentWindow(Document document) { |
402 | 413 |
Class<? extends IDocumentWindow> defaultDocumentClass = |
403 | 414 |
document.getFactory().getMainWindowClass(); |
Also available in: Unified diff