MCPcopy Create free account
hub / github.com/ArtifexSoftware/mupdf / messageBox

Method messageBox

platform/java/example/Viewer.java:147–162  ·  view source on GitHub ↗
(Frame owner, String title, String message)

Source from the content-addressed store, hash-verified

145 protected Mark[] marks = new Mark[10];
146
147 protected static void messageBox(Frame owner, String title, String message) {
148 final Dialog box = new Dialog(owner, title, true);
149 box.add(new Label(message), BorderLayout.CENTER);
150 Panel buttonPane = new Panel(new FlowLayout());
151 Button okayButton = new Button("Okay");
152 okayButton.addActionListener(new ActionListener() {
153 public void actionPerformed(ActionEvent event) {
154 box.setVisible(false);
155 }
156 });
157 buttonPane.add(okayButton);
158 box.add(buttonPane, BorderLayout.SOUTH);
159 box.pack();
160 box.setVisible(true);
161 box.dispose();
162 }
163
164 protected static String passwordDialog(Frame owner, String title) {
165 final Dialog box = new Dialog(owner, title, true);

Callers 1

mainMethod · 0.95

Calls 3

packMethod · 0.80
disposeMethod · 0.80
addMethod · 0.45

Tested by

no test coverage detected