MapFrame.java
资源名称:MapModule.rar [点击查看]
上传用户:njlgjx
上传日期:2022-08-07
资源大小:9105k
文件大小:2k
源码类别:
图形图象
开发平台:
Java
- /*
- * MapFrame.java
- *
- * Created on 2008年6月24日, 下午4:22
- */
- package com.mwq.map;
- import com.mwq.map.tool.ScreenSize;
- /**
- *
- * @author Administrator
- */
- public class MapFrame extends javax.swing.JFrame {
- /** Creates new form MapFrame */
- public MapFrame() {
- initComponents();
- setBounds((ScreenSize.getWidth()-getWidth())/2, (ScreenSize.getHeight()-getHeight())/2, getWidth(), getHeight());
- }
- /** This method is called from within the constructor to
- * initialize the form.
- * WARNING: Do NOT modify this code. The content of this method is
- * always regenerated by the Form Editor.
- */
- @SuppressWarnings("unchecked")
- // <editor-fold defaultstate="collapsed" desc="Generated Code">//GEN-BEGIN:initComponents
- private void initComponents() {
- mapPanel = new com.mwq.map.MapPanel();
- setDefaultCloseOperation(javax.swing.WindowConstants.EXIT_ON_CLOSE);
- setTitle("电子地图");
- getContentPane().setLayout(new java.awt.GridLayout(1, 0));
- getContentPane().add(mapPanel);
- pack();
- }// </editor-fold>//GEN-END:initComponents
- /**
- * @param args the command line arguments
- */
- public static void main(String args[]) {
- java.awt.EventQueue.invokeLater(new Runnable() {
- public void run() {
- new MapFrame().setVisible(true);
- }
- });
- }
- // Variables declaration - do not modify//GEN-BEGIN:variables
- private com.mwq.map.MapPanel mapPanel;
- // End of variables declaration//GEN-END:variables
- }