侧边按钮在IE Edge中不起作用

时间:2015-10-14 08:57:34

标签: html css asp.net twitter-bootstrap

目标:
右边的侧边按钮应该适用于最新的IE,CHrome和FF。

问题:
它仅适用于Chrome和FF,但不适用于Edge。 代码来自此网页(https://www.softwareag.com/corporate/rc/rc_perma.asp?id=tcm:16-123797),它在Edge中完美运行。

我坚信这与Edge相关的引导程序有关。不知道如何解决它。

谢谢!

的信息:
*我使用的是Bootstrap v2和asp.net mvc *源代码示例如下 *我在大开发阶段使用了源代码示例。

enter image description here



import java.awt.*;
import java.awt.event.*;
import javax.swing.*;

public class JButtonFocusBorder extends JFrame {

    private JPanel panel;
    private JTextField textfield1;
    private JLabel label1;
    private JTextField textfield2;
    private JLabel label2;
    private JCheckBox checkbox1;
    private JButton button;

    public JButtonFocusBorder() {
        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
        setLayout(new BorderLayout());

        initComponents();

        label1.setBorder(BorderFactory.createEmptyBorder(1, 1, 1, 1));
        label2.setBorder(BorderFactory.createEmptyBorder(1, 1, 1, 1));

        label1.setFocusable(true);
        label2.setFocusable(true);

        FocusListener focusListener = new FocusAdapter() {

            @Override
            public void focusGained(FocusEvent e) {
                JLabel label = (JLabel) e.getSource();
                // looking for a replacement of this
                label.setBorder(UIManager.getBorder("List.focusCellHighlightBorder"));
            }

            @Override
            public void focusLost(FocusEvent e) {
                JLabel label = (JLabel) e.getSource();
                label.setBorder(BorderFactory.createEmptyBorder(1, 1, 1, 1));
            }
        };
        label1.addFocusListener(focusListener);
        label2.addFocusListener(focusListener);

        MouseListener mouseListener = new MouseAdapter() {

            @Override
            public void mouseClicked(MouseEvent e) {
                JLabel label = (JLabel) e.getSource();
                label.requestFocusInWindow();
            }

        };
        label1.addMouseListener(mouseListener);
        label2.addMouseListener(mouseListener);

        pack();
        setResizable(false);
        setLocationRelativeTo(null);
    }

    private void initComponents() {
        panel = new JPanel(new GridBagLayout());
        add(panel);

        GridBagConstraints gbc;

        label1 = new JLabel("Field1:");
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 0;
        panel.add(label1, gbc);        

        textfield1 = new JTextField(20);
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 0;
        panel.add(textfield1, gbc);

        label2 = new JLabel("Field2:");
        gbc = new GridBagConstraints();
        gbc.gridx = 0;
        gbc.gridy = 1;
        panel.add(label2, gbc);        

        textfield2 = new JTextField(20);
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 1;
        panel.add(textfield2, gbc);

        checkbox1 = new JCheckBox("CheckBox1");
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 2;
        panel.add(checkbox1, gbc);

        button = new JButton("Apply");
        gbc = new GridBagConstraints();
        gbc.gridx = 1;
        gbc.gridy = 3;
        panel.add(button, gbc);
    }

    public static void main(String[] args) throws 
            ClassNotFoundException, UnsupportedLookAndFeelException, 
            InstantiationException, IllegalAccessException {
        UIManager.setLookAndFeel(
                    UIManager.getSystemLookAndFeelClassName());


        SwingUtilities.invokeLater(new Runnable() {

            @Override
            public void run() {
                new JButtonFocusBorder().setVisible(true);
            }
        });
    }

}

p {
    font-size: 24px;
}

#foo {
    position:fixed;
    right:0;
    display:block;
    top:400px;
    width:128px;
    height:128px;
    background: #f00 url('http://icons.iconarchive.com/icons/uiconstock/50-free-christmas/128/candy-2-icon.png') no-repeat 50% 50%;
  
  

}

#fooo {
    position:fixed;
    left:0;
    display:block;
    top:400px;
    width:128px;
    height:128px;
    background: #f00 url('http://icons.iconarchive.com/icons/uiconstock/50-free-christmas/128/candy-2-icon.png') no-repeat 50% 50%;
  

}




1 个答案:

答案 0 :(得分:0)

尝试添加此CSS

%macro createData(n);

 %do i=1 %to &n;
    Proc transpose data=x.output&i out=work.var&i;
    run;
 %end;
%mend;

%createdata(10);