Uploaded image for project: 'Jalview'
  1. Jalview
  2. JAL-3031

Generalise Desktop.instance and Desktop.desktop for flexible window management

    XMLWordPrintable

    Details

    • Type: Task
    • Status: In Progress
    • Priority: Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 2.12.0_js
    • Component/s: jalview-j2s
    • Labels:
      None

      Description

      Desktop has static fields 'desktop' and 'instance'.

      MyDesktopPane Desktop.desktop:
        - acts as the parent for dialogs (JvOptionPane methods and similar) (as a Component)
        - is the Component to which new frames are added, by Desktop.addInternalFrame()
        - provides MyDesktopPane.showMemoryUsage()

      Desktop Desktop.instance
        - is tested for null (to check for headless operation)
        - provides getAllFrames()
        - is the target for method calls such as Desktop.instance.inputLocalFileMenuItem_actionPerformed()
        - is the ClipboardOwner
        - acts as a context provider (applet or desktop) for example to StructureSelectionManager.getStructureSelectionManager()
        - provides the Progress Bar
        - is the owner of a JDialog created by JalviewDialog.initDialogFrame() or WsJobParameters.showRunDialog()
        - is referenced for maximum dimensions of new panels

      Would like to generalise and separate out these uses somehow
      - to allow a different 'parent' to be injected for dialogs (generalise Desktop.desktop)
      - to allow panels or internal frames to be added (generalise Desktop.instance and Desktop.addInternalFrame())
      - specifically for a JalviewJS gui with a top level frame

        Attachments

          Issue Links

            Activity

              People

              Assignee:
              jprocter James Procter
              Reporter:
              gmungoc Mungo Carstairs
              Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

                Dates

                Created:
                Updated: