You are viewing a plain text version of this content. The canonical link for it is here.
Posted to jmeter-dev@jakarta.apache.org by Chris Povirk <ch...@paytec.com> on 2004/06/08 21:44:00 UTC
[PATCH] Bug 22818 and similar: Table entries lost on focus change
http://nagoya.apache.org/bugzilla/show_bug.cgi?id=22818
Okay, this one's a confirmed bug, so I shouldn't be breaking any proper behavior *this* time. It seems that the implementation of HTTPArgumentsPanel is slightly different than that of ArgumentsPanel; still, the method someone wrote to avoid this problem in ArgumentsPanel works fine with HTTPArgumentsPanel, as well. The fixes for the other four files are essentially identical.
Again, do advise if there are any problems.
--Chris
--- jakarta-jmeter/src/core/org/apache/jmeter/config/gui/SimpleConfigGui.java.orig 2004-06-08 14:12:08.424808176 -0500
+++ jakarta-jmeter/src/core/org/apache/jmeter/config/gui/SimpleConfigGui.java 2004-06-08 14:12:49.359585144 -0500
@@ -150,6 +150,11 @@
*/
public void modifyTestElement(TestElement el)
{
+ if(table.isEditing())
+ {
+ table.getCellEditor().stopCellEditing();
+ }
+
Data model = tableModel.getData();
model.reset();
while (model.next())
--- jakarta-jmeter/src/components/org/apache/jmeter/modifiers/gui/UserParametersGui.java.orig 2004-06-08 14:13:19.090065424 -0500
+++ jakarta-jmeter/src/components/org/apache/jmeter/modifiers/gui/UserParametersGui.java 2004-06-08 14:14:15.355511776 -0500
@@ -118,6 +118,10 @@
*/
public void modifyTestElement(TestElement params)
{
+ if(paramTable.isEditing())
+ {
+ paramTable.getCellEditor().stopCellEditing();
+ }
((UserParameters) params).setNames(
new CollectionProperty(
UserParameters.NAMES,
--- jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/gui/HTTPArgumentsPanel.java.orig 2004-06-08 14:15:00.053716616 -0500
+++ jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/gui/HTTPArgumentsPanel.java 2004-06-08 14:17:42.697990928 -0500
@@ -100,6 +100,7 @@
public TestElement createTestElement()
{
+ stopTableEditing();
Iterator modelData = tableModel.iterator();
Arguments args = new Arguments();
while (modelData.hasNext())
--- jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/gui/AuthPanel.java.orig 2004-06-08 14:15:00.049717224 -0500
+++ jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/gui/AuthPanel.java 2004-06-08 14:16:31.636793872 -0500
@@ -100,6 +100,10 @@
*/
public void modifyTestElement(TestElement el)
{
+ if(authTable.isEditing())
+ {
+ authTable.getCellEditor().stopCellEditing();
+ }
el.clear();
el.addTestElement((TestElement) tableModel.manager.clone());
configureTestElement(el);
--- jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/gui/CookiePanel.java.orig 2004-06-08 14:15:00.025720872 -0500
+++ jakarta-jmeter/src/protocol/http/org/apache/jmeter/protocol/http/gui/CookiePanel.java 2004-06-08 14:17:07.470346344 -0500
@@ -262,6 +262,10 @@
*/
public void modifyTestElement(TestElement cm)
{
+ if(cookieTable.isEditing())
+ {
+ cookieTable.getCellEditor().stopCellEditing();
+ }
cm.clear();
configureTestElement(cm);
if (cm instanceof CookieManager)
---------------------------------------------------------------------
To unsubscribe, e-mail: jmeter-dev-unsubscribe@jakarta.apache.org
For additional commands, e-mail: jmeter-dev-help@jakarta.apache.org