Closed GoogleCodeExporter closed 8 years ago
A window with the message "Documentation started" has been added to provide
immediate
response to a user pending a click on the Documentation button. The window will
automatically close as soon as the progress bar for DITA Rendering of the
document
appears.
public void build()
{
if ((project.isOpen()) && project.isAccessible())
{
UIJob report = new UIJob("Run Report")
{
public IStatus runInUIThread(IProgressMonitor monitor)
{
//Indicate a message that documentation has started
JPanel displayPanel = new JPanel() {
public void paintComponent(Graphics g) {
super.paintComponent(g);
g.drawString( "Documentation
starting...", 30, 30 );
}
};
JPanel content = new JPanel();
content.setLayout(new BorderLayout());
content.add(displayPanel, BorderLayout.CENTER);
JFrame window = new JFrame("");
//window.setUndecorated(true);
//window.setIconImage(null);
window.setResizable(false);
window.setContentPane(content);
window.setSize(250,100);
window.setLocation(400,300);
window.setVisible(true);
// monitor.beginTask("in progress...",
// IProgressMonitor.UNKNOWN);
// Create images first
ImageCreation imageCreation = new ImageCreation();
imageCreation.createImages(monitor);
// Create items based on DITA Map
createReportItems(monitor);
window.dispose();
antJob();
return Status.OK_STATUS;
}
};
// report.setUser(true);
report.schedule();
}
}
I did not use JOptionPane.showMessageDialog because i could not find a way of
closing
ing it programmatically. So i used JPanel to paint the message and JFrame to
display
it. The problem now is how to set a relative path to
C:\helinks\workspaces\r2be\com.helinks.sts.product.sts_si\icons\Helinks16.gif
Original comment by Alberto.Perri@googlemail.com
on 30 Mar 2010 at 1:06
Original comment by Alberto.Perri@googlemail.com
on 30 Mar 2010 at 7:18
Original issue reported on code.google.com by
joer...@gmail.com
on 28 Mar 2010 at 11:25