ui.forms.widgets.Hyperlink : Summary: 1 Cursor(s) Exception in (0):
yidabu
yidabu.spam at gmail.com
Fri Jun 13 21:13:24 PDT 2008
code bellow not crashed, but cause Exception:
Summary: 1 Cursor(s) Exception in (0):
when exit program, ddbg captured :
Unhandled D Exception (tango.core.Exception.IOException
"<console> :: The handle is invalid.") at KERNEL32.dll (0x7c812a5b) thread(2644
)
Does it means some resource not auto released ?
Or Hyperlink works with dwtx.ui.forms.widgets.Form only ?
Code:
module DwtTest;
import dwt.DWT;
import dwt.widgets.Display;
import dwt.widgets.Shell;
import dwtx.ui.forms.widgets.Hyperlink;
void main(){
Display display = new Display ();
Shell shell = new Shell (display);
/// cause Summary: 1 Cursor(s) Exception in (0):
auto linkHome = new Hyperlink(shell, DWT.NONE);
linkHome.setText(" http://www.d-programming-language-china.org/ ");
linkHome.setUnderlined(true);
linkHome.setForeground(shell.getDisplay().getSystemColor(DWT.COLOR_BLUE));
linkHome.setSize (300, 200); //to show the link
shell.pack();
shell.open ();
while (!shell.isDisposed ()) {
if (!display.readAndDispatch ()) display.sleep ();
}
display.dispose ();
}
--
yidabu <yidabu.spam at gmail.com>
http://www.dsource.org/projects/dwin
D 语言-中文(D Chinese):
http://www.d-programming-language-china.org/
http://bbs.d-programming-language-china.org/
http://dwin.d-programming-language-china.org/
http://scite4d.d-programming-language-china.org/
More information about the Digitalmars-d-dwt
mailing list