Fundamental question: disable the GUI while RMI is communicating?

Good afternoon,
I'm using RMI in a swing application and i have fundamental question:
I have a jlist with categories and another jlist which displays the items of the selected category. When a user selects a category rmi is used to get the items of the selected category from the server (internet).
Should i disable the whole application while rmi is communicating with the server? For example with a glasspane with a cancel button.
What is the best practice in this case?
Best regards,
James

I found a really nice solution, now i call my remote methods like:
taskManager.executeAction(new ITaskResult(){
      public void done(Object result) {
        Collections.sort(rpcs, new RpcComperator());
        fireContentsChanged(this, 0, getSize());
      public void failed(Exception e) {
        WindowUtils.showErrorDialog(owner, "Could not change server");
    }, new IAction(){
      public Object action() throws DBException, AccessException {
        return taskManager.getBasic().changeRpc(rpc);
    }, true);The first parameter of executeAction() is a object which gets notified when a task completes (done()) or fails (failed()). The second parameter is a object which indicates which remote functions should be called. And finally the third parameter defines if the user should wait until the remote function completes.
If the user should wait the executeAction() function shows a nice modal dialog with a progressbar and a cancel button. If the user doesn't have to wait it takes the progressbar on the statusbar to indicate the system is busy.
Much rewriting was needed, but i think it is quite simple and it is fully swing thread save. But it wonders me that such a thing wasn't available.

Similar Messages

  • How to disable the trackpad while typing on mbp without mouse ?

    how to disable the trackpad while typing on mbp without mouse ?

    Like Kappysaid :
    Kappy wrote:
    Open Universal Access preferences. Under either the Keyboard or Mouse tab should be a checkbox option to prevent accidental input when typing. If you don't find it there then check in the Trackpad preferences.
    or find the apple instructions here http://support.apple.com/kb/HT3608
    Good luck

  • Disable the Textfield while editing the HTML form item

    How to disable a texfield while editing the HTML form item ? It should be enabled while creating the new form entry / record.
    Yogesh

    Yogesh,
    If you 'disable' an item and submits (UPDATE) the page, then disabled item value won't get submitted. So the disabled item value will get updated with NULL or you will get any validation failures messages, if you have any.
    Better option would be, make the item read-only during Update. For the text item for which you want disable, edit that item,goto 'Read-only Conditions', here set the condition so that user can't edit it during UPDATE. Here you can use same conditions as of your 'UPDATE' button 'display conditions'
    Regards,
    Hari

  • Question about the concept of RMI reverse calls.

    Hello guys.
    I'd appreciate if someone could clarify something to me. As far as I understand , RMI reverse call in concept, is the mean thought witch a server can remotely call a method belonging to the client.
    I've done that like this: the client called a method from to the server(classic rmi) , method that had the particularity to received as a parameter an instance of a serialized .class belonging to client. Through that received remote object it seems the server can call specific methods belonging to the client .class.
    I'm not sure it's the correct way to do reverse calls, but what puzzles me is that shouldn't the server be able to call a client method without first needing to receive that instance of the client's .class and implicitly being dependent on that client initial call (maybe to get that .class in a different way)?

    I'm not sure it's the correct way to do reverse callsIt's not. If the object passed to the server is serializable, the server can call methods on it, but they will execute at the server.
    The object you pass to the server must be an exported remote object. Then the server callbacks will execute at the client.
    but what puzzles me is that shouldn't the server be able to call a client method without first needing to receive that instance of the client's .classNo, why?
    and implicitly being dependent on that client initial call (maybe to get that .class in a different way)?When you get the exported remote object part right, the remote method via which the client passes the callback to the server will declare the callback as a remote interface, not as the implementing class at the client.

  • How can I disable the screensaver while playing video in fullscreen?

    Hi!
    HTML5 is great and I hope to get rid of Flash as soon as possible.
    That said, something is still bothering me when I play an HTML5 video (on youtube for instance): the screensaver is still on even though I'm full-screen.
    Is there a config I missed or is it a bug within Firefox?
    (I'm using Arch Linux with GNOME)

    Per this comment - https://bugzilla.mozilla.org/show_bug.cgi?id=517870#c36 - a fix is in the works for Firefox 30.

  • Want to disable the password while running rsh command on solaris 10

    Hi,
    After executing rsh command it is asking for a password. I want to login to a target machine with rsh command through the scripts which it shouldnot ask for a password. It will be appreciated if anyone can help me in solving out this issue?

    Please type:
    echo "+" > /.rhosts
    or
    echo "%host name of the machine you want to connect%" > /.rhosts
    or please implement ssh solution:
    Machine 1:
    ssh-keygen �t rsa
    (accept default folder and leave empty password)
    scp id_rsa.pub root@%ip_Machine2%:/root/.ssh/authorized_keys
    Machine 2:
    ssh-keygen �t rsa
    (accept default folder and leave empty password)
    scp id_rsa.pub root@%ip_Machine1%:/root/.ssh/authorized_keys
    Regards,
    Daniel

  • Disable checkbox lists while clicking Radio button

    Hi ,
    I have a checkbox list come from LOV based on a select from database table.
    I have added a Radiobutton only (not redirect not submit since I have to restrict the option as this is based on requirement).Now I want to disable the checkbox while I am clicking the radio button .
    Is it any way possible .
    Thanks in advance .
    Cheers,
    Debashis.

    ok, I create two radio buttons (Enable and Disable)(P8_RADIO). I created a LOV of users with checkboxes (P8_CHECK). When I click on disable all the checkboxes are disabled and enabled when I click on enable.
    First add this to your radio
    P8_RADIO's HTML Form Element Attributes
    onclick="disable(this)"
    Then, add this to the page HTML Header
    <script language="JavaScript" type="text/javascript">
    <!--
    function disable(pThis)
    var trigger = document.wwv_flow.p_v02.value ;
    var rads = document.wwv_flow.p_v02 ;
    if (pThis.value == 'ENABLE')
    for(var i=0; i<rads.length;i++ )
    { document.wwv_flow.p_v02[i].disabled = false; }
    } //end of if
    else
    for(var i=0; i<rads.length;i++ )
    { document.wwv_flow.p_v02[i].disabled = true; }
    } //end of else
    } //end of disable funtion
    //-->
    </script>
    **note**p_v02 is the name of the checkboxes.
    Hopefully this will help you and i explained it better than I did last time

  • I need help with the GUI nad Graphic 2D....

    Hi
    i'm kind new to java and i have couple of questions... all my questions about the GUI...
    when i want to create a GUI programe , and when i want to draw a graphic with GUI, i do that way(code)
    "public class x1 extends JPanle{
         public void PaintComponent(Graphic g){
    My questions:
    1) why do i have to extend from JPanle ??
    2) Why do i use paintcomponent??? why i couldn't use directly 'Graphic g' ??
    This code i get it from the book, this is how it is done...
    Also, if i want to draw some shapes(rec, circle ..etc) and i want to put Button and organize them, how could i do that???
    i tried to organize the button after i draw the rectangle but i can't... all becaus of the stupid way'the code that i wrote it', i hope there is an alternative way.
    My last question... how can i change the font ???
    i want to use 'sans comic'...
    Thanks alot....

    kiiwii14 wrote:
    i'm kind new to java and i have couple of questions...fair enough.
    all my questions about the GUI...and that's your problem right there.
    Your questions tell me that you're missing quite a few fundamentals of programming in Java. There's nothing wrong with that, everyone starts this way. But if you try to do any GUI programming at your current level you will run head-first into many, many problems that could be easily avoided if you concentrate on learning the basics first.
    when i want to create a GUI programe , and when i want to draw a graphic with GUI, i do that way(code)
    "public class x1 extends JPanle{That code doesn't compile. It's JPanel, not JPanle. Please post only compiling code (or near it, if you've got a question about a compiler error).
         public void PaintComponent(Graphic g){"paintCompontent", not "PaintComponent".
    Oh, and in the future please use the CODE-Button when posting code (1. copy+paste code 2. select code 3. press "CODE" just above the text area).
    My questions:
    1) why do i have to extend from JPanle ??You don't have to. You can, if you want your class to be a specific type of JPanel.
    2) Why do i use paintcomponent??? why i couldn't use directly 'Graphic g' ??How would you "directly use Graphic g"?
    That's the way the framework is written. Components draw themselves using that method. If you want to change how they draw themselves you can override that method.
    Did you read the chapter that tells you this or did you simply copy out the code example? The examples are there to illustrate the points and help you understand. They are not a *substitute* to actually reading the text.
    Also, if i want to draw some shapes(rec, circle ..etc) and i want to put Button and organize them, how could i do that???Finish reading the book, write some basic programs and then work on from there.
    You're trying to learn a feature and produce a useful product at the same time. I can tell you from experience that this is a very bad idea.
    i tried to organize the button after i draw the rectangle but i can't... How did you try?
    all becaus of the stupid way'the code that i wrote it', i hope there is an alternative way.You didn't show us your attempt so we can't tell you any alternative.
    My last question... how can i change the font ???
    i want to use 'sans comic'... Hm ... "Comic Sans" is the name. And that's not a font. [It's a desease|http://bancomicsans.com/].

  • [SOLVED] Disable ps2 mouse while typing

    I've seen multiple guides for disabling the touchpad while typing.  I've got an alps touchpad which still isn't recognized after trying out the 2 different alps drivers in the aur. 
    My problem is that I can't use synclient because the touchpad is not recognized as a synaptics device.  I can manually disable the touchpad using xinput.  How do I automatically disable it when I am typing?
    Last edited by nstone (2015-01-18 00:52:41)

    The tool at https://bbs.archlinux.org/viewtopic.php?id=96610 detects keyboard activity by looking at /proc/interrupts and can be used to disable or enable the touchpad.
    Last edited by lucke (2015-01-17 22:29:12)

  • How to disable the select options button, while audio is playing in the question template in captivate 8?

    How to disable the select options button, while audio is playing in the question template in captivate 8?

    Apologies for late reply.
    I mean "On Question screens audio keeps on playing even after we have selected an option or options depending on the question type and clicked Submit. How do we stop the audio on selecting an option?"

  • Is there anyway to disable the chime when I accidentally catch the microphone icon while texting (phone is in silent mode)

    Hi all,
    I might be being a little dull here, but my question is exacly as in the title: Is there anyway to disable the chime when I accidentally catch the microphone icon while texting (phone is in silent mode)?  I have fat fingers occasionally and whilst people at work don't mind private phone usage to have it occasionally activating the mic and then me cancelling it a little annoying.
    Any suggestions?
    Thanks
    Dave

    There is a proximity sensor that should turn the screen off when you place the phone near your face.  Do you have a case that's blocking this?  Try removing your case.  If no case, try restoring you iPhone.  If still a problem, return it to Apple for a warranty replacement.

  • How can I disable the annoying orange outline while I tap a link or a input area?

    i'm a user of Firefox for android. i've found a problem since I update to 16.0.2 and above. every time i tap a link or a input text in the web page, there always shows an annoying orange rectangle outline around the focused link or input area. Moreover, this outline would keep showing while I drag the page and start browsing other parts of the same page. how can I disable the annoying feature?

    This is the default feature of the browser to indicate which element are you on, if you are actually on focus with the input or tapping on the right link.
    Since this is a default feature of the browser, it now depends on the website's developer to override this feature with custom focus styles. Normally, in a browser, you can override this with user styles/scripts but as far as I know, Firefox Android does not support such features.
    However, I found [https://support.mozilla.org/en-US/questions/929362 an article] that states that there is a [https://addons.mozilla.org/en-US/firefox/addon/stylish/ plugin] that is compatible with Firefox Android that handles user styles.

  • I would like to buy an iPhone for my friend in Iceland.  Two questions: will the phone work with complete utility in Iceland, and if so, what should I do to confirgure it while in the USA so that it can have full utility in Iceland?

    I would like to buy an iPhone for my friend in Iceland.  Two questions: will the phone work with complete utility in Iceland, and if so, what should I do to confirgure it while in the USA so that it can have full utility in Iceland?

    Bad idea. There are no supported iPhone carriers in Iceland, thus some features may or may not work. Further, there will be no warranty or support for a US purchased iPhone in Iceland...your friend will be on their own. If you still want to go down this road, make sure you purchase an officially unlocked iPhone(GSM model) directly from Apple.

  • How to know whether the javascript is disabled or not while loading the jsp

    Hi,
    My query is like how to know whether the javascript is disabled or not while loading the Application main JSP in Mozilla browser.
    I want some Java code or JavaScript code.

    To the point, just let JS fire a specific HTTP request inside the same session.
    This can be done in several ways. 1) Create a hidden <img> element and set the `src` attribute so that it will request a (fake) image from the server. The server just have to intercept on this specific request. 2) Fire an ajaxical request and let the server intercept on it. You can use a Filter for this which sets a token in the session scope to inform that the client has JS enabled.

  • How to update the apps while disable Settings General Restrictions Installing Apps  ??

    Hi
    I will give my old iPad to my mom and I would like to disable  "Settings>General>Restrictions>Installing Apps"  so that she or other famliy kids will not unintentionally install some bad/garbage apps.
    But I found a problem, without Apps Store, the apps already there will not be updated any more !!  Am I right?
    It seems that we need Apps Store for apps update, but disabling the "Settings>General>Restrictions>Installing Apps" will remove the Apps Store.
    Does anybody know any way to work around? I mean the apps already there could be update while "Settings>General>Restrictions>Installing Apps" is disabled.
    Thanks a lot !!

    stanleyoowa wrote:
    You mean I need to unhidden the App Store everytime when I want to update the apps ?
    And then re-hidden the App Store to enforce the restriction again?
    It is reasonable, but sounds like ... not that handy ......
    I just wonder could I use "icloud" to enforce the apps update??
    Purchases, yes, but I don't think it works for updates.

Maybe you are looking for

  • How to get the key values of record in ADF Read-only Form?

    Hi I am using ADF Business Component VO. I have a search page( ADF Search Form) and I am displaying the results of the search in a ADF Read-Only Table( only few columns are shown) .Then by selecting a record and clicking on the button 'View' , I am n

  • Acrobat 9.4 Pro PDF-Printer

    Hi everybody, i have a word file (Word 2011 Release) with underline text in font verdana. When i create a pdf via "print" and select the adobe printer the underline is gone. I created a Microsoft Support Ticket, but they say its not a word problem. W

  • With both ApplyMRU and ApplyMRD, does one commit before the other runs?

    This is related to another thread at How to stop insert of new row in tabular form if it's also being deleted I wanted to ask this question separately, however, for broader understanding. I have a tabular form configured so that if a user clicks on "

  • HT1369 I can't get my computer to connect me to the itunes store

    I'm able to listen to my purchased music but i can't go to the store to purchase. I keep getting an error that its not connected to the network

  • How to distinquish different versions of QT in AS

    Hi all, In trying to debug an Applescript using QuickTime, I've run across an issue I'm not sure how to solve in AS. I have both QuickTime 5.0.2 in Classic, and QT Pro 6.5.3 in Mac OSX 10.2.8. When I run test scripts with QT Pro 6.5.3 already up, the