summaryrefslogtreecommitdiff
path: root/java/demo/Ice/swing/Client.java
diff options
context:
space:
mode:
Diffstat (limited to 'java/demo/Ice/swing/Client.java')
-rw-r--r--java/demo/Ice/swing/Client.java14
1 files changed, 13 insertions, 1 deletions
diff --git a/java/demo/Ice/swing/Client.java b/java/demo/Ice/swing/Client.java
index c4530badc0a..e7bb118f04d 100644
--- a/java/demo/Ice/swing/Client.java
+++ b/java/demo/Ice/swing/Client.java
@@ -460,6 +460,13 @@ public class Client extends JFrame
prx = prx.ice_invocationTimeout(timeout);
}
_helloPrx = Demo.HelloPrxHelper.uncheckedCast(prx);
+
+ //
+ // The batch requests associated to the proxy are lost when we
+ // update the proxy.
+ //
+ _flush.setEnabled(false);
+
_status.setText("Ready");
}
@@ -583,7 +590,12 @@ public class Client extends JFrame
private void flush()
{
- _communicator.begin_flushBatchRequests(new Ice.Callback_Communicator_flushBatchRequests()
+ if(_helloPrx == null)
+ {
+ return;
+ }
+
+ _helloPrx.begin_ice_flushBatchRequests(new Ice.Callback_Object_ice_flushBatchRequests()
{
@Override
public void exception(final Ice.LocalException ex)