incubator-ooo-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From bugzi...@apache.org
Subject DO NOT REPLY [Bug 118896] New: BASIC needs a throwRuntimeException() function
Date Fri, 10 Feb 2012 12:14:57 GMT
https://issues.apache.org/ooo/show_bug.cgi?id=118896

             Bug #: 118896
        Issue Type: DEFECT
           Summary: BASIC needs a throwRuntimeException() function
    Classification: Code
           Product: scripting
           Version: version58
          Platform: All
        OS/Version: All
            Status: CONFIRMED
          Severity: enhancement
          Priority: P3
         Component: code
        AssignedTo: kr@openoffice.org
        ReportedBy: donjaime@freenet.de
                CC: ooo-issues@incubator.apache.org


There are some things that can only be done by throwing an exception.

For example, Page 13 of
http://www.openoffice.org/documentation/HOW_TO/various_topics/VbaStarBasicXref.pdf,
addressing the differences between VBA and OOo BASIC happily states that "To
cancel the close in OOo, you must
register a listener for the close event and then veto the close."

But at
http://www.openoffice.org/api/docs/common/ref/com/sun/star/util/XCloseListener.html
we read that to veto the close the listener has to throw a closeVetoException.
Which BASIC can't do. So you have to jump through a lot of hoops, register a
dispatch interceptor, crash the application if you get it wrong, etc.

Something like throwRuntimeException("com.sun.star.util.CloseVetoException")
would make life easier.

-- 
Configure bugmail: https://issues.apache.org/ooo/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.

Mime
View raw message