From 1e40ead687022214033b8e1a1c1c4ebc083914f4 Mon Sep 17 00:00:00 2001 From: Jim Procter Date: Thu, 27 Nov 2014 10:29:00 +0000 Subject: [PATCH] JAL-966 promote getName to an api method --- src/jalview/api/AlignmentViewPanel.java | 6 ++++++ src/jalview/appletgui/AlignmentPanel.java | 6 ++++++ src/jalview/gui/AlignmentPanel.java | 7 ++----- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/src/jalview/api/AlignmentViewPanel.java b/src/jalview/api/AlignmentViewPanel.java index 7ff3a6a..0955cb4 100644 --- a/src/jalview/api/AlignmentViewPanel.java +++ b/src/jalview/api/AlignmentViewPanel.java @@ -50,4 +50,10 @@ public interface AlignmentViewPanel extends OOMHandlerI * ensuring the alignment is still visible. */ void adjustAnnotationHeight(); + + /** + * + * @return displayed name for the view + */ + String getViewName(); } diff --git a/src/jalview/appletgui/AlignmentPanel.java b/src/jalview/appletgui/AlignmentPanel.java index 02ad0cd..5062874 100644 --- a/src/jalview/appletgui/AlignmentPanel.java +++ b/src/jalview/appletgui/AlignmentPanel.java @@ -965,6 +965,12 @@ public class AlignmentPanel extends Panel implements AdjustmentListener, } @Override + public String getViewName() + { + return getName(); + } + + @Override public StructureSelectionManager getStructureSelectionManager() { return StructureSelectionManager diff --git a/src/jalview/gui/AlignmentPanel.java b/src/jalview/gui/AlignmentPanel.java index 5527f1e..2398bda 100644 --- a/src/jalview/gui/AlignmentPanel.java +++ b/src/jalview/gui/AlignmentPanel.java @@ -1503,11 +1503,8 @@ public class AlignmentPanel extends GAlignmentPanel implements return av.getAlignment(); } - /** - * get the name for this view - * - * @return - */ + + @Override public String getViewName() { return av.viewName; -- 1.7.10.2