comparison dwt/browser/Browser.d @ 350:373b48b9eaf0

Conclusion of long painful debugging: working Browser package :) (aplha)
author John Reimer <terminal.node@gmail.com>
date Sun, 02 Nov 2008 01:30:09 -0800
parents 8198e6052012
children 4bffbf81e2d6
comparison
equal deleted inserted replaced
349:676785ef6d24 350:373b48b9eaf0
13 module dwt.browser.Browser; 13 module dwt.browser.Browser;
14 14
15 import dwt.dwthelper.utils; 15 import dwt.dwthelper.utils;
16 16
17 import tango.core.Thread; 17 import tango.core.Thread;
18 import tango.io.Stdout;
18 19
19 import dwt.DWT; 20 import dwt.DWT;
20 import dwt.DWTError; 21 import dwt.DWTError;
21 import dwt.DWTException; 22 import dwt.DWTException;
22 import dwt.widgets.Composite; 23 import dwt.widgets.Composite;
366 return webBrowser.back (); 367 return webBrowser.back ();
367 } 368 }
368 369
369 protected void checkSubclass () { 370 protected void checkSubclass () {
370 String name = this.classinfo.name; 371 String name = this.classinfo.name;
371 372 name = name.substring(0, name.lastIndexOf('.'));
372 int index = tango.text.Util.locatePrior(name, '.'); 373 int index = name.lastIndexOf('.');
373 if (!(name[0 .. index + 1] == PACKAGE_PREFIX)) { 374 if (!name.substring (0, index + 1).equals (PACKAGE_PREFIX)) {
375 Stdout ("name: ")(name.substring(0, index + 1))(" == " )(PACKAGE_PREFIX).newline;
374 DWT.error (DWT.ERROR_INVALID_SUBCLASS); 376 DWT.error (DWT.ERROR_INVALID_SUBCLASS);
375 } 377 }
376 } 378 }
377 379
378 /** 380 /**