Package org.geoforge.appogcecl.actioncontroller

Source Code of org.geoforge.appogcecl.actioncontroller.GfrAcrSpcAppPrsPrjManAbs

/*
*  Copyright (C) 2011-2014 GeoForge Project
*
*  This program is free software: you can redistribute it and/or modify
*  it under the terms of the GNU Lesser General Public License as published by
*  the Free Software Foundation, either version 3 of the License, or
*  (at your option) any later version.
*
*  This program is distributed in the hope that it will be useful,
*  but WITHOUT ANY WARRANTY; without even the implied warranty of
*  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
*  GNU Lesser General Public License for more details.
*
*  You should have received a copy of the GNU Lesser General Public License
*  along with this program.  If not, see <http://www.gnu.org/licenses/>.
*/
package org.geoforge.appogcecl.actioncontroller;

import java.util.logging.Logger;
import javax.swing.JFrame;
import org.geoforge.appogcecl.actionmanager.GfrAmrAppPrsManAbs;
import org.geoforge.java.util.logging.filehandler.FileHandlerLogger;
import org.geoforge.guillc.GfrAppSpcAbs;
import org.geoforge.guillc.dialog.DlgAbs;
import org.geoforge.guillc.optionpane.GfrOptionPaneAbs;
import org.geoforge.guillc.dialog.GfrDlgTabsPrefsPrsMan;
import org.geoforge.guillc.menuitem.GfrMimTrsAlrIdNewWinZoomLlosVarJfcChartAbs;
import org.geoforge.guillc.menuitem.GfrMimTrsAlrIdNewWinZoomMloFixJfcChartAbs;
import org.geoforge.guillc.menuitem.GfrMimTrsAlrIdNewWinZoomTloJfcChartSingleAbs;
import org.geoforge.guillc.menuitem.GfrMimTrsAlrIdNewWinZoomTloWwdEarthAlwaysAbs;
import org.geoforge.guillcogcecl.frame.GfrFrmMainAppOgcEclAbs;
import org.geoforge.io.serial.GfrSerializeStateWwdMan;
import org.geoforge.lang.util.GfrResBundleLang;

/**
*
* @author bantchao
*
* email: bantchao_AT_gmail.com
* ... please remove "_AT_" from the above string to get the right email address
*
*
*/
abstract public class GfrAcrSpcAppPrsPrjManAbs extends GfrAcrSpcAppPrsPrjAbs
{
   // ----
   // begin: instantiate logger for this class

   final private static Logger _LOGGER_ = Logger.getLogger(GfrAcrSpcAppPrsPrjManAbs.class.getName());

   static
   {
      GfrAcrSpcAppPrsPrjManAbs._LOGGER_.addHandler(FileHandlerLogger.s_getInstance());
   }

   // end: instantiate logger for this class
   // ----
  
   protected GfrAcrSpcAppPrsPrjManAbs(GfrAppSpcAbs app, GfrAmrAppPrsManAbs amr)
         throws Exception
   {
      super(app,
            amr,
            GfrResBundleLang.s_getInstance().getValue("verb.manage").toLowerCase());

   }

   public void moveObjectsWwdEarthHandler(JFrame frmOwner) throws Exception
   {
      GfrFrmMainAppOgcEclAbs frm = (GfrFrmMainAppOgcEclAbs) frmOwner;

      String strStateOrbitViewSource = frm.getRestorableStateOrbitViewManage();

      if (strStateOrbitViewSource != null)
      {
         GfrSerializeStateWwdMan.s_write(strStateOrbitViewSource);
      }
   }

   @Override
   protected void _showObjectInNewViewerTopsWwdEarth(GfrMimTrsAlrIdNewWinZoomTloWwdEarthAlwaysAbs mim)
   {
      throw new UnsupportedOperationException("Not yet implemented");
   }

   @Override
   protected void _showObjectInNewViewerTloJfcChart(GfrMimTrsAlrIdNewWinZoomTloJfcChartSingleAbs mim)
   {
      throw new UnsupportedOperationException("Not yet implemented");
   }


    @Override
   public void preferencesAppliHandler()
   {
      try
      {
         DlgAbs dlg = new GfrDlgTabsPrefsPrsMan();

         if (!dlg.init())
         {
            String str = "! dlg.init()";
            throw new Exception(str);
         }

         dlg.setVisible(true);
      }
      catch (Exception exc)
      {
         exc.printStackTrace();
         String str = exc.getMessage();
         GfrAcrSpcAppPrsPrjManAbs._LOGGER_.severe(str);
         GfrOptionPaneAbs.s_showDialogError(null, str);
      }
   }

   @Override
   public boolean init()
   {
      if (!super.init())
         return false;


      return true;
   }

   @Override
   public void destroy()
   {
      super.destroy();
   }

   @Override
   public void open() throws Exception
   {
      super.open();

      _readStateWorldwind();
   }

   @Override
   public void close() throws Exception
   {
      super.close();

      _writeStateWorldwind();
   }

   private void _writeStateWorldwind() throws Exception
   {
   }

   private void _readStateWorldwind() throws Exception
   {
   }

   @Override
   protected void _showObjectInNewViewerMloFixJfcChart(GfrMimTrsAlrIdNewWinZoomMloFixJfcChartAbs mim)
   {
      throw new UnsupportedOperationException("Not supported yet.");
   }

   @Override
   protected void _showObjectInNewViewerLlosVarJfcChart(GfrMimTrsAlrIdNewWinZoomLlosVarJfcChartAbs mim)
   {
      throw new UnsupportedOperationException("Not supported yet.");
   }
}
TOP

Related Classes of org.geoforge.appogcecl.actioncontroller.GfrAcrSpcAppPrsPrjManAbs

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.