incubator-ooo-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Gerardo Gómez <gerardo.g...@gmail.com>
Subject Re: Problem when showing a dialog of a deployed extension
Date Mon, 07 Nov 2011 05:29:37 GMT
Yes, i had already set a breakpoint, and i don't think the problem is on
the UploadDialog.java, because i can execute it separately from the
extension. It only happens, when i deploy it (from netbeans), to my
OpenOffice.org. This is the code i use to show/hide a dialog

    public void setVisible(boolean visible){
//        If this dialog is modal...
        if (modal){
            if (visible){
//                ...it uses execute to show the dialog.
                this.xDialog.execute();
            }
            else{
//                ...it uses endExecute to hide the dialog.
                this.xDialog.endExecute();
            }
        }
//        If this dialog is not modal...
        else{
//            ...it uses the setVisible method from the xWindow object.
            this.xWindow.setVisible(visible);
        }
    }

It seems also, that either in the extension execution and the execution
from the main method, has the same parameters (a null string).

public void fillCredentials(Creditionals creditionals) {

this.getRememberPassCheckBox().setState(creditionals.getWsCreditionalsReadedFromDisk());
//      credentionals.getUserName() == null
        this.getUserNameTextField().setText(creditionals.getUserName());
        this.getPasswordTextField().setText(creditionals.getPassword());
    }

public void setText(String text){
        this.xTextComponent.setText(text);
    }

I'm not an UNO expert, but maybe the resources are managed in a different
way when deploying to an extension than executing UNO code from a main
method.

Thank you for your suggestion.

On Sun, Nov 6, 2011 at 11:09 PM, Ariel Constenla-Haile <
ariel.constenla.haile@gmail.com> wrote:

> Hello Gerardo,
>
> On Sun, Nov 06, 2011 at 10:06:29PM -0600, Gerardo Gómez wrote:
> > Hello everyone.
> > I have a problem when i try to show some dialogs of an extension i've
> > modified. But this error has a peculiarity, it only happens with some
> > dialogs, other dialogs can be showed. The error showed on the console is
> > this one:
> >
> > com.sun.star.uno.RuntimeException: [jni_uno bridge error] Java calling
> UNO
> > method setText: [map_to_uno():string] null-ref given!
> > java stack trace:
> >         at com.sun.star.bridges.jni_uno.JNI_proxy.dispatch_call(Native
> > Method)
> >         at
> com.sun.star.bridges.jni_uno.JNI_proxy.invoke(JNI_proxy.java:175)
> >         at $Proxy36.setText(Unknown Source)
> >         at util.OoTextField.setText(OoTextField.java:50)
> >         at
> > org.openoffice.gdocs.ui.LoginPanel.fillCredentials(LoginPanel.java:179)
> >         at
> > org.openoffice.gdocs.ui.LoginPanel.readCreditionals(LoginPanel.java:202)
> >         at
> org.openoffice.gdocs.ui.LoginPanel.setSystem(LoginPanel.java:212)
> >         at
> >
> org.openoffice.gdocs.ui.dialogs.UploadDialog.<init>(UploadDialog.java:181)
> >         at org.openoffice.gdocs.UNOGDocs$2.run(UNOGDocs.java:231)
> >         at java.lang.Thread.run(Thread.java:662)
> >
> > I'm developing the extension on NetBeans 6.8, deploying the OXT file on
> > OpenOffice.org 3.3 and the dialog i try to show is from the UNO-AWT. If
> you
> > have any idea how can i solve this problem would be really appreciated.
>
> without seeing any code, it is hard to guess. Did you already set
> a breakpoint at UploadDialog.java:181 and see why you are sending the
> message setText to a null object?
>
> Regards
> --
> Ariel Constenla-Haile
> La Plata, Argentina
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message