// Path: src/travis/model/project/StructStub.java
// public class StructStub {
// 
//     public enum Visibility {
//         DEFAULT(0), PUBLIC(Opcodes.ACC_PUBLIC), PRIVATE(Opcodes.ACC_PRIVATE), PROTECTED(
//                 Opcodes.ACC_PROTECTED);
// 
//         private final int opcode;
// 
//         private Visibility(int opcode) {
//             this.opcode = opcode;
//         }
// 
//         public String toString() {
//             return super.toString().toLowerCase();
//         }
//     }
// 
//     public enum Modifier {
//         NONE(0), FINAL(Opcodes.ACC_FINAL), ABSTRACT(Opcodes.ACC_ABSTRACT), STATIC(
//                 Opcodes.ACC_STATIC);
// 
//         private final int opcode;
// 
//         private Modifier(int opcode) {
//             this.opcode = opcode;
//         }
// 
//         public String toString() {
//             return super.toString().toLowerCase();
//         }
//     }
// 
//     public enum Inheritance {
//         NONE(0), INTERFACE(Opcodes.ACC_INTERFACE), ABSTRACT(
//                 Opcodes.ACC_ABSTRACT), FINAL(Opcodes.ACC_FINAL), ENUM(
//                 Opcodes.ACC_ENUM);
// 
//         private final int opcode;
// 
//         private Inheritance(int opcode) {
//             this.opcode = opcode;
//         }
// 
//         public String toString() {
//             return super.toString().toLowerCase();
//         }
//     }
// 
//     private String name;
//     private String descriptor;
//     private int accessFlag;
// 
//     public StructStub() {
//         this("");
//     }
// 
//     public StructStub(String name) {
//         this.name = name;
//         this.descriptor = "";
//     }
// 
//     public void setVisibility(Visibility visibility) {
//         accessFlag |= visibility.opcode;
//     }
// 
//     public void setModifier(Modifier modifier) {
//         accessFlag |= modifier.opcode;
//     }
// 
//     public void setInheritance(Inheritance inheritance) {
//         accessFlag |= inheritance.opcode;
//     }
// 
//     public int getAccessFlag() {
//         return accessFlag;
//     }
// 
//     public void setAccessFlag(int accessFlag) {
//         this.accessFlag = accessFlag;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
//     public String getDescriptor() {
//         return descriptor.replace('.', '/');
//     }
// 
//     public void setDescriptor(String descriptor) {
//         this.descriptor = descriptor;
//     }
// 
// }
// 
// Path: src/travis/util/Messages.java
// public final class Messages {
//     private static final ResourceBundle messages;
// 
//     static {
//         messages = ResourceBundle.getBundle(
//                 "travis.resources.messages", Locale.getDefault());
//     }
// 
//     private Messages() {
//     }
// 
//     public static String get(String key) {
//         return messages.getString(key);
//     }
// 
//     public static String format(String key, Object... args) {
//         return MessageFormat.format(get(key), args);
//     }
// }


import javax.swing.JComboBox;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JTextField;
import javax.swing.JTextPane;
import net.miginfocom.swing.MigLayout;
import travis.model.project.StructStub;
import travis.util.Messages;
/*
 * MethodDialogPanel.java
 *
 * Copyright (C) 2011-2012, Artur Jonkisz, <travis.source@gmail.com>
 *
 * This file is part of TraVis.
 * See https://github.com/ajonkisz/TraVis for more info.
 *
 * TraVis is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * TraVis 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 General Public License for more details.
 * You should have received a copy of the GNU General Public License
 * along with TraVis.  If not, see <http://www.gnu.org/licenses/>.
 */

package travis.view.project.tree.popup;



public class MethodDialogPanel extends DialogPanel {

    private static final String STYLE = "<style type='text/css'>"
            + "table {background-color: #000000; padding: 1px 0px 0px 1px}"
            + "th {background-color: #ffffff; margin:0px 0.5px 0.5px 0px}"
            + "td {background-color: #ffffff; margin:0.5px 0.5px 0px 0px; font-family: 'Monaco'}"
            + "</style>";
    private static final String INFO_RETURN = "<html>" + STYLE
            + "<body><table>" + "<tr><th>" + Messages.get("java.type")
            + "</th><th>" + Messages.get("type.desc") + "</th></tr>"
            + "<tr><td>void</td><td>V</td></tr>"
            + "<tr><td>boolean</td><td>Z</td></tr>"
            + "<tr><td>char</td><td>C</td></tr>"
            + "<tr><td>byte</td><td>B</td></tr>"
            + "<tr><td>short</td><td>S</td></tr>"
            + "<tr><td>int</td><td>I</td></tr>"
            + "<tr><td>float</td><td>F</td></tr>"
            + "<tr><td>long</td><td>J</td></tr>"
            + "<tr><td>double</td><td>D</td></tr>"
            + "<tr><td>Object</td><td>Ljava.lang.Object;</td></tr>"
            + "<tr><td>int</td><td>[I</td></tr>"
            + "<tr><td>Object[][]</td><td>[[Ljava.lang.Object;</td></tr>"
            + "</table></body></html>";
    private static final String INFO_PARAM = "<html>"
            + STYLE
            + "<body><table>"
            + "<tr><th>"
            + Messages.get("parameter.source")
// Path: src/travis/model/project/StructStub.java
// public class StructStub {
// 
//     public enum Visibility {
//         DEFAULT(0), PUBLIC(Opcodes.ACC_PUBLIC), PRIVATE(Opcodes.ACC_PRIVATE), PROTECTED(
//                 Opcodes.ACC_PROTECTED);
// 
//         private final int opcode;
// 
//         private Visibility(int opcode) {
//             this.opcode = opcode;
//         }
// 
//         public String toString() {
//             return super.toString().toLowerCase();
//         }
//     }
// 
//     public enum Modifier {
//         NONE(0), FINAL(Opcodes.ACC_FINAL), ABSTRACT(Opcodes.ACC_ABSTRACT), STATIC(
//                 Opcodes.ACC_STATIC);
// 
//         private final int opcode;
// 
//         private Modifier(int opcode) {
//             this.opcode = opcode;
//         }
// 
//         public String toString() {
//             return super.toString().toLowerCase();
//         }
//     }
// 
//     public enum Inheritance {
//         NONE(0), INTERFACE(Opcodes.ACC_INTERFACE), ABSTRACT(
//                 Opcodes.ACC_ABSTRACT), FINAL(Opcodes.ACC_FINAL), ENUM(
//                 Opcodes.ACC_ENUM);
// 
//         private final int opcode;
// 
//         private Inheritance(int opcode) {
//             this.opcode = opcode;
//         }
// 
//         public String toString() {
//             return super.toString().toLowerCase();
//         }
//     }
// 
//     private String name;
//     private String descriptor;
//     private int accessFlag;
// 
//     public StructStub() {
//         this("");
//     }
// 
//     public StructStub(String name) {
//         this.name = name;
//         this.descriptor = "";
//     }
// 
//     public void setVisibility(Visibility visibility) {
//         accessFlag |= visibility.opcode;
//     }
// 
//     public void setModifier(Modifier modifier) {
//         accessFlag |= modifier.opcode;
//     }
// 
//     public void setInheritance(Inheritance inheritance) {
//         accessFlag |= inheritance.opcode;
//     }
// 
//     public int getAccessFlag() {
//         return accessFlag;
//     }
// 
//     public void setAccessFlag(int accessFlag) {
//         this.accessFlag = accessFlag;
//     }
// 
//     public String getName() {
//         return name;
//     }
// 
//     public void setName(String name) {
//         this.name = name;
//     }
// 
//     public String getDescriptor() {
//         return descriptor.replace('.', '/');
//     }
// 
//     public void setDescriptor(String descriptor) {
//         this.descriptor = descriptor;
//     }
// 
// }
// 
// Path: src/travis/util/Messages.java
// public final class Messages {
//     private static final ResourceBundle messages;
// 
//     static {
//         messages = ResourceBundle.getBundle(
//                 "travis.resources.messages", Locale.getDefault());
//     }
// 
//     private Messages() {
//     }
// 
//     public static String get(String key) {
//         return messages.getString(key);
//     }
// 
//     public static String format(String key, Object... args) {
//         return MessageFormat.format(get(key), args);
//     }
// }


// Path: src/travis/view/project/tree/popup/MethodDialogPanel.java
import javax.swing.JComboBox;
import javax.swing.JLabel;
import javax.swing.JPanel;
import javax.swing.JTextField;
import javax.swing.JTextPane;
import net.miginfocom.swing.MigLayout;
import travis.model.project.StructStub;
import travis.util.Messages;

/*
 * MethodDialogPanel.java
 *
 * Copyright (C) 2011-2012, Artur Jonkisz, <travis.source@gmail.com>
 *
 * This file is part of TraVis.
 * See https://github.com/ajonkisz/TraVis for more info.
 *
 * TraVis is free software: you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation, either version 3 of the License, or
 * (at your option) any later version.
 *
 * TraVis 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 General Public License for more details.
 * You should have received a copy of the GNU General Public License
 * along with TraVis.  If not, see <http://www.gnu.org/licenses/>.
 */

package travis.view.project.tree.popup;



public class MethodDialogPanel extends DialogPanel {

    private static final String STYLE = "<style type='text/css'>"
            + "table {background-color: #000000; padding: 1px 0px 0px 1px}"
            + "th {background-color: #ffffff; margin:0px 0.5px 0.5px 0px}"
            + "td {background-color: #ffffff; margin:0.5px 0.5px 0px 0px; font-family: 'Monaco'}"
            + "</style>";
    private static final String INFO_RETURN = "<html>" + STYLE
            + "<body><table>" + "<tr><th>" + Messages.get("java.type")
            + "</th><th>" + Messages.get("type.desc") + "</th></tr>"
            + "<tr><td>void</td><td>V</td></tr>"
            + "<tr><td>boolean</td><td>Z</td></tr>"
            + "<tr><td>char</td><td>C</td></tr>"
            + "<tr><td>byte</td><td>B</td></tr>"
            + "<tr><td>short</td><td>S</td></tr>"
            + "<tr><td>int</td><td>I</td></tr>"
            + "<tr><td>float</td><td>F</td></tr>"
            + "<tr><td>long</td><td>J</td></tr>"
            + "<tr><td>double</td><td>D</td></tr>"
            + "<tr><td>Object</td><td>Ljava.lang.Object;</td></tr>"
            + "<tr><td>int</td><td>[I</td></tr>"
            + "<tr><td>Object[][]</td><td>[[Ljava.lang.Object;</td></tr>"
            + "</table></body></html>";
    private static final String INFO_PARAM = "<html>"
            + STYLE
            + "<body><table>"
            + "<tr><th>"
            + Messages.get("parameter.source")
            + "</th><th>"