Package com.sun.star.awt

Examples of com.sun.star.awt.XDialog


     private void handleCrashReporterDialog(boolean cancel, boolean YesNo){
        try{
           
            log.println("try to get Crash Reporter Dialog...");
           
            XDialog oDialog = rt.getActiveDialog(xMSF);
            assure("could not get CrashReporter Dialog", oDialog != null);
           
            XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, oDialog);
           
            log.println(oDialog.getTitle());

            UITools oUITools = new UITools(xMSF, xWindow);

            if (cancel) {
                log.println("clicking 'Cancel' button...");
View Full Code Here


    private void handleRecoveryDialogAtRestart(int expectedDocumentCount, boolean recover, boolean cancel){
        try{
           
            log.println("try to get Recovery Dialog...");

            XDialog oDialog = null;
            oDialog = rt.getActiveDialogAfterStartup(xMSF);
           
            assure("could not get Recovery Dialog at start of office", (oDialog != null), CONTINUE);
           
            XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, oDialog);
            log.println("got the following dialog: '" +oDialog.getTitle() + "'");

            UITools oUITools = new UITools(xMSF, xWindow);

            String listBoxName = "Status of recovered documents";
            String[] documents = oUITools.getListBoxItems(listBoxName);
View Full Code Here

        return xPS;
    }

    public static XDialog CreateSimpleDialog( XComponentContext xContext, String sURL, int nTitleID, String[] pControls, int[] pStringIDs )
    {
        XDialog xResult = null;

        if ( xContext != null && sURL != null && sURL.length() > 0 )
        {
            try
            {
View Full Code Here

            {
                ex.printStackTrace();
            }

            final WikiPropDialog aThisDialog = this;
            final XDialog xDialogToClose = xDialog;
            final XComponentContext xContext = m_xContext;

            // start spinning
            SetThrobberVisible( true );
            SetThrobberActive( true );
           
            // the following method might show a dialog, should be used in main thread
            final Hashtable aWikiSettings = m_aSettings.getSettingByUrl( m_sWikiEngineURL );
            if ( Helper.AllowThreadUsage( m_xContext ) )
            {
                m_aThread = new Thread( "com.sun.star.thread.WikiEditorSendingThread" )
                {
                    public void run()
                    {
                        try
                        {
                            if ( m_aWikiEditor != null )
                            {
                                Thread.yield();
                                m_bAction = m_aWikiEditor.SendArticleImpl( aThisDialog, aWikiSettings );
                            }
                        }
                        finally
                        {
                            EnableControls( true );
                            SetThrobberActive( false );
                            SetThrobberVisible( false );

                            ThreadStop( true );
                            if ( m_bAction )
                                MainThreadDialogExecutor.Close( xContext, xDialogToClose );
                        }
                    }
                };

                m_aThread.start();
            }
            else
            {
                try
                {
                    if ( m_aWikiEditor != null )
                    {
                        m_bAction = m_aWikiEditor.SendArticleImpl( aThisDialog, aWikiSettings );
                    }
                } catch( java.lang.Exception e )
                {}
                finally
                {
                    EnableControls( true );
                    SetThrobberActive( false );
                    SetThrobberVisible( false );

                    if ( m_bAction )
                        xDialogToClose.endExecute();
                }
            }
                      
            return true;
        }
View Full Code Here

            SetThrobberVisible( true );
            SetThrobberActive( true );

            if ( Helper.AllowThreadUsage( m_xContext ) )
            {
                final XDialog xDialogForThread = xDialog;
                final XComponentContext xContext = m_xContext;
                final WikiEditSettingDialog aThis = this;
               
                // the thread name is used to allow the error dialogs
                m_bThreadFinished = false;
View Full Code Here

        }

        XDialogProvider2 xDialogProvider = (XDialogProvider2)
          UnoRuntime.queryInterface( XDialogProvider2.class, obj );
           
        XDialog xDialog = xDialogProvider.createDialogWithHandler( DialogURL, this );
        if( xDialog != null )
          xDialog.execute();
      }
      catch (Exception e) {
        e.printStackTrace();
      }
      return "Created dialog \"" + DialogURL + "\"";
View Full Code Here

            XWindow.class, xControl );
        xWindow.setVisible( false );     
        xControl.createPeer( xToolkit, null );
     
        // return the dialog
        XDialog xDialog = ( XDialog )UnoRuntime.queryInterface(
            XDialog.class, dialog );
        return xDialog;
    }
View Full Code Here

            UnoRuntime.queryInterface(XTreeControl.class, xDialogContainer.getControl( sTreeControlName ));
           
            xTreeControl.expandNode(xNode);
            oObj = xTreeControl;

          XDialog xDialog = (XDialog) UnoRuntime.queryInterface(XDialog.class, xDialogControl);
           
            execurteDialog aDialog = new execurteDialog(xDialog);
           
            aDialog.start();
           
View Full Code Here

            log.println("wating for recovery dialog...");
           
            int counter = 0;
            int maximum = param.getInt(PropertyName.THREAD_TIME_OUT) / param.getInt(PropertyName.SHORT_WAIT);
           
            XDialog oDialog = rt.getActiveDialog(xMSF);
           
            while ( oDialog == null && (counter < maximum))
            {
                rt.pause();
                oDialog = rt.getActiveDialog(xMSF);               
View Full Code Here

     private void handleCrashReporterDialog(boolean cancel, boolean YesNo){
        try{
           
            log.println("try to get Crash Reporter Dialog...");
           
            XDialog oDialog = rt.getActiveDialog(xMSF);
            assure("could not get CrashReporter Dialog", oDialog != null);
           
            XWindow xWindow = (XWindow) UnoRuntime.queryInterface(XWindow.class, oDialog);
           
            log.println(oDialog.getTitle());

            UITools oUITools = new UITools(xMSF, xWindow);

            if (cancel) {
                log.println("clicking 'Cancel' button...");
View Full Code Here

TOP

Related Classes of com.sun.star.awt.XDialog

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.