Morning,

yep... java crossplatform... well, lets think about it ;)

it turns out that the file that I actually changed was the 
DataSourceQueryChooserDialog

====
the change was as follows:

     void okCancelPanel_actionPerformed(ActionEvent e) {
         if (!okCancelPanel.wasOKPressed() ||
                 getCurrentChooser().isInputValid()) {
             setVisible(false);
         }
         // sstein: added else-if to fix MAC-OSX-bug
         else if((okCancelPanel.wasOKPressed()) && (CheckOS.isMacOsx())) {
                //--sstein: leave out validation - because it returns always 
"false" on Mac-OSX ?
                //System.out.println("validate input:" + 
getCurrentChooser().isInputValid());
                //System.out.println("i am inside");
                okCancelPanel.setOKPressed(true);
                setVisible(false);
         }
     }

so,It would probably need to be applied to 
SaveFileDataSourceQueryChooser ???

====

have a good day - I just started mine.
stefan


Am 25.10.11 05:25, schrieb edgar.sol...@web.de:
> On 25.10.2011 07:29, Stefan Steiniger wrote:
>> Hei Ede,
>>
>> BUG 1: I did a test and it's negative - i.e. doesn't work as we where
>> thinking.
>> SaveDatasetAsFile works but not SaveDatasetAs,
>
> which is really weird, because essentially both use jfilechooser, though the 
> logic to retrieve the selected file seems to be much complexer in 
> SaveDatasetAsFile
>
> SaveDatasetAs seems to ignore the entered file name, right.
>
>> Because for the other one (which has now the field) the ok button
>> doesn't work. I assume that there is no input taken from the field,
>> because when I used the other dialog in between I could actually save
>> [see stack trace below] - but it did use the layers name to save and not
>> the name I typed in. I think the fact that the ok button didn't work was
>> one of our first issues that we noticed on Macs.. long time ago.
>
> have to look at the actual "fix". requested the changeset in the other mail 
> so i can look what was changed.
>
> i more and more think i should leave it and simply create a savewizard with 
> types on the left (file,database ...) reusing the new framework and not 
> wasting time on the legacy code.
>
>>
>> BUG 2: And.. while testing I was lucky and found another very
>> problematic bug:
>> If a new feature was drawn, then I can't call the feature context menu.
>> Both, the alt key and the mac/apple key switch to a zoom mode. Also,
>> while usually context menus are called with "ctrl", in OJ the layer
>> context menu is called with the Mac/apple key (though.. some other
>> programs may do that too)
>
> good catch, i enabled right click in macosx which seems to work fine. will 
> check control/leftclick though.
>
>> so far for this night :(
>
> somebody sayd java is crossplatfrom ;) ain't it .. :)ede
>
>> stefan
>>
>> PS: stack trace:
>> well.. I can't repeat the initial error, but instead OJ is writing a
>> file with the layer name straight (i.e. still not accepting my input).
>> But when I change the box for the file format and change the name again
>> I cannot save and this stack trace follow:
>>
>> Exception in thread "AWT-EventQueue-0" java.lang.NullPointerException
>>      at
>> com.vividsolutions.jump.workbench.datasource.SaveFileDataSourceQueryChooser.isInputValid(SaveFileDataSourceQueryChooser.java:135)
>>      at
>> com.vividsolutions.jump.workbench.datasource.DataSourceQueryChooserDialog.okCancelPanel_actionPerformed(DataSourceQueryChooserDialog.java:186)
>>      at
>> com.vividsolutions.jump.workbench.datasource.DataSourceQueryChooserDialog$5.actionPerformed(DataSourceQueryChooserDialog.java:139)
>>      at
>> com.vividsolutions.jump.workbench.ui.ButtonPanel.fireActionPerformed(ButtonPanel.java:109)
>>      at
>> com.vividsolutions.jump.workbench.ui.ButtonPanel.access$0(ButtonPanel.java:106)
>>      at
>> com.vividsolutions.jump.workbench.ui.ButtonPanel$1.actionPerformed(ButtonPanel.java:91)
>>      at 
>> javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2028)
>>      at
>> javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2351)
>>      at
>> javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
>>      at 
>> javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
>>      at
>> javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236)
>>      at java.awt.Component.processMouseEvent(Component.java:6373)
>>      at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
>>      at java.awt.Component.processEvent(Component.java:6138)
>>      at java.awt.Container.processEvent(Container.java:2085)
>>      at java.awt.Component.dispatchEventImpl(Component.java:4735)
>>      at java.awt.Container.dispatchEventImpl(Container.java:2143)
>>      at java.awt.Component.dispatchEvent(Component.java:4565)
>>      at 
>> java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4621)
>>      at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4282)
>>      at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4212)
>>      at java.awt.Container.dispatchEventImpl(Container.java:2129)
>>      at java.awt.Window.dispatchEventImpl(Window.java:2478)
>>      at java.awt.Component.dispatchEvent(Component.java:4565)
>>      at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:679)
>>      at java.awt.EventQueue.access$000(EventQueue.java:85)
>>      at java.awt.EventQueue$1.run(EventQueue.java:638)
>>      at java.awt.EventQueue$1.run(EventQueue.java:636)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>      at
>> java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
>>      at
>> java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
>>      at java.awt.EventQueue$2.run(EventQueue.java:652)
>>      at java.awt.EventQueue$2.run(EventQueue.java:650)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>      at
>> java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
>>      at java.awt.EventQueue.dispatchEvent(EventQueue.java:649)
>>      at
>> java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
>>      at
>> java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
>>      at
>> java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:205)
>>      at java.awt.Dialog$1.run(Dialog.java:1046)
>>      at java.awt.Dialog$3.run(Dialog.java:1098)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>      at java.awt.Dialog.show(Dialog.java:1096)
>>      at java.awt.Component.show(Component.java:1584)
>>      at java.awt.Component.setVisible(Component.java:1536)
>>      at java.awt.Window.setVisible(Window.java:842)
>>      at java.awt.Dialog.setVisible(Dialog.java:986)
>>      at
>> com.vividsolutions.jump.workbench.datasource.SaveDatasetAsPlugIn.showDialog(SaveDatasetAsPlugIn.java:61)
>>      at
>> com.vividsolutions.jump.workbench.datasource.AbstractLoadSaveDatasetPlugIn.execute(AbstractLoadSaveDatasetPlugIn.java:37)
>>      at
>> com.vividsolutions.jump.workbench.plugin.AbstractPlugIn$1.actionPerformed(AbstractPlugIn.java:130)
>>      at 
>> javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:2028)
>>      at
>> javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2351)
>>      at
>> javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387)
>>      at 
>> javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242)
>>      at javax.swing.AbstractButton.doClick(AbstractButton.java:389)
>>      at 
>> javax.swing.plaf.basic.BasicMenuItemUI.doClick(BasicMenuItemUI.java:809)
>>      at com.apple.laf.AquaMenuItemUI.doClick(AquaMenuItemUI.java:137)
>>      at
>> javax.swing.plaf.basic.BasicMenuItemUI$Handler.mouseReleased(BasicMenuItemUI.java:850)
>>      at java.awt.Component.processMouseEvent(Component.java:6373)
>>      at javax.swing.JComponent.processMouseEvent(JComponent.java:3267)
>>      at java.awt.Component.processEvent(Component.java:6138)
>>      at java.awt.Container.processEvent(Container.java:2085)
>>      at java.awt.Component.dispatchEventImpl(Component.java:4735)
>>      at java.awt.Container.dispatchEventImpl(Container.java:2143)
>>      at java.awt.Component.dispatchEvent(Component.java:4565)
>>      at 
>> java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4621)
>>      at java.awt.LightweightDispatcher.processMouseEvent(Container.java:4282)
>>      at java.awt.LightweightDispatcher.dispatchEvent(Container.java:4212)
>>      at java.awt.Container.dispatchEventImpl(Container.java:2129)
>>      at java.awt.Window.dispatchEventImpl(Window.java:2478)
>>      at java.awt.Component.dispatchEvent(Component.java:4565)
>>      at java.awt.EventQueue.dispatchEventImpl(EventQueue.java:679)
>>      at java.awt.EventQueue.access$000(EventQueue.java:85)
>>      at java.awt.EventQueue$1.run(EventQueue.java:638)
>>      at java.awt.EventQueue$1.run(EventQueue.java:636)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>      at
>> java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
>>      at
>> java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:98)
>>      at java.awt.EventQueue$2.run(EventQueue.java:652)
>>      at java.awt.EventQueue$2.run(EventQueue.java:650)
>>      at java.security.AccessController.doPrivileged(Native Method)
>>      at
>> java.security.AccessControlContext$1.doIntersectionPrivilege(AccessControlContext.java:87)
>>      at java.awt.EventQueue.dispatchEvent(EventQueue.java:649)
>>      at
>> java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:296)
>>      at
>> java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:211)
>>      at
>> java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:201)
>>      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:196)
>>      at java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:188)
>>      at java.awt.EventDispatchThread.run(EventDispatchThread.java:122)
>>
>>
>> Am 24.10.11 15:21, schrieb Michaël Michaud:
>>> Hi,
>>>
>>> Thanks for the fix, Ede,
>>>
>>>> and are you sure that this dialog also saves to postgis? what do i
>>>> need to do to have postgis in the dropdown fields?
>>> PluginPostgis sourcecode is on the svn
>>> SaveDatasetAs... Postgis should be available in OpenJUMP-PLUS
>>>> the postgis plugin that comes with OJ Plus - I think (not being a
>>>> postgis user either).
>>>> But if you want to try... the OGRS 2009 tutorial has a part on how to
>>>> use OJ&    PostGIS.
>>> And Uwe updated his nice german tutorial in 2010 :
>>> http://sourceforge.net/projects/jump-pilot/files/Documentation/PostGIS%20Tutorial%20%28for%20external%20Plugin%29/
>>>
>>> Michaël
>>>>
>>>> cheers,
>>>> stefan
>>>>
>>>>> ..ede
>>>>>
>>>>>
>>>>> On 24.10.2011 01:02, Michaël Michaud wrote:
>>>>>> Hi Stefan,
>>>>>>
>>>>>>> For proper bugfixng of "Save Dataset As..." I am lacking time until now,
>>>>>>> unfortunately, to figure what actually happens. An assumption is that
>>>>>>> somehow one selection box overlays the text field? Mhm.. wasn't the
>>>>>>> selection box once above, Michael? just some thought.
>>>>>> Did you try to remove the code I added in 2007 in SaveDatasetAsPlugIn ?
>>>>>> It could be related to textfield visibility.
>>>>>> Have you a sreenshot of what happens on MacOSX ?
>>>>>> // initialize the FileChooser with the layer name [mmichaud 2007-08-25]
>>>>>>                         FileChooserPanel fcp =
>>>>>> (FileChooserPanel)context.getBlackboard().get(SaveFileDataSourceQueryChooser.FILE_CHOOSER_PANEL_KEY);
>>>>>>                         if (fcp != null) {
>>>>>>                             JFileChooser jfc = fcp.getChooser();
>>>>>>                             jfc.setSelectedFile(new
>>>>>> File(jfc.getCurrentDirectory(),
>>>>>>
>>>>>> context.getLayerNamePanel().getSelectedLayers()[0].getName()));
>>>>>>                         }
>>>>>>
>>>>>> Michaël
>>>>>>
>>>>>>> stefan
>>>>>>>
>>>>>>>
>>>>>>> Am 23.10.11 08:33, schrieb edgar.sol...@web.de:
>>>>>>>> On 23.10.2011 13:17, edgar.sol...@web.de wrote:
>>>>>>>>> On 22.10.2011 20:18, Stefan Steiniger wrote:
>>>>>>>>>> So, I added next to the "Save Dataset As..." function in
>>>>>>>>>> the layer context menu a new "Save Dataset As File..." function. This
>>>>>>>>>> can be used to save to arbitrary files on MacOSX now. But note, this
>>>>>>>>>> function is only loaded on MacOSX.
>>>>>>>>> why didn't you fix the old dialog?
>>>>>>>>> now there are two. wouldn't it make sense to remove one of them?
>>>>>>>>>
>>>>>>>> ahh.. i saw you commit comment about postgis saving. still, don't you 
>>>>>>>> think we should merge these dialogs?
>>>>>>>>
>>>>>>>> ..ede
>>>>>>>>
>>>>>>>> ------------------------------------------------------------------------------
>>>>>>>> The demand for IT networking professionals continues to grow, and the
>>>>>>>> demand for specialized networking skills is growing even more rapidly.
>>>>>>>> Take a complimentary Learning@Cisco Self-Assessment and learn
>>>>>>>> about Cisco certifications, training, and career opportunities.
>>>>>>>> http://p.sf.net/sfu/cisco-dev2dev
>>>>>>>> _______________________________________________
>>>>>>>> Jump-pilot-devel mailing list
>>>>>>>> Jump-pilot-devel@lists.sourceforge.net
>>>>>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>>>>>> ------------------------------------------------------------------------------
>>>>>>> The demand for IT networking professionals continues to grow, and the
>>>>>>> demand for specialized networking skills is growing even more rapidly.
>>>>>>> Take a complimentary Learning@Cisco Self-Assessment and learn
>>>>>>> about Cisco certifications, training, and career opportunities.
>>>>>>> http://p.sf.net/sfu/cisco-dev2dev
>>>>>>> _______________________________________________
>>>>>>> Jump-pilot-devel mailing list
>>>>>>> Jump-pilot-devel@lists.sourceforge.net
>>>>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>>>>>>
>>>>>>>
>>>>>> ------------------------------------------------------------------------------
>>>>>> The demand for IT networking professionals continues to grow, and the
>>>>>> demand for specialized networking skills is growing even more rapidly.
>>>>>> Take a complimentary Learning@Cisco Self-Assessment and learn
>>>>>> about Cisco certifications, training, and career opportunities.
>>>>>> http://p.sf.net/sfu/cisco-dev2dev
>>>>>> _______________________________________________
>>>>>> Jump-pilot-devel mailing list
>>>>>> Jump-pilot-devel@lists.sourceforge.net
>>>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>>>> ------------------------------------------------------------------------------
>>>>> The demand for IT networking professionals continues to grow, and the
>>>>> demand for specialized networking skills is growing even more rapidly.
>>>>> Take a complimentary Learning@Cisco Self-Assessment and learn
>>>>> about Cisco certifications, training, and career opportunities.
>>>>> http://p.sf.net/sfu/cisco-dev2dev
>>>>> _______________________________________________
>>>>> Jump-pilot-devel mailing list
>>>>> Jump-pilot-devel@lists.sourceforge.net
>>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>>> ------------------------------------------------------------------------------
>>>> The demand for IT networking professionals continues to grow, and the
>>>> demand for specialized networking skills is growing even more rapidly.
>>>> Take a complimentary Learning@Cisco Self-Assessment and learn
>>>> about Cisco certifications, training, and career opportunities.
>>>> http://p.sf.net/sfu/cisco-dev2dev
>>>> _______________________________________________
>>>> Jump-pilot-devel mailing list
>>>> Jump-pilot-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> The demand for IT networking professionals continues to grow, and the
>>> demand for specialized networking skills is growing even more rapidly.
>>> Take a complimentary Learning@Cisco Self-Assessment and learn
>>> about Cisco certifications, training, and career opportunities.
>>> http://p.sf.net/sfu/cisco-dev2dev
>>> _______________________________________________
>>> Jump-pilot-devel mailing list
>>> Jump-pilot-devel@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>
>> ------------------------------------------------------------------------------
>> The demand for IT networking professionals continues to grow, and the
>> demand for specialized networking skills is growing even more rapidly.
>> Take a complimentary Learning@Cisco Self-Assessment and learn
>> about Cisco certifications, training, and career opportunities.
>> http://p.sf.net/sfu/cisco-dev2dev
>> _______________________________________________
>> Jump-pilot-devel mailing list
>> Jump-pilot-devel@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>
> ------------------------------------------------------------------------------
> The demand for IT networking professionals continues to grow, and the
> demand for specialized networking skills is growing even more rapidly.
> Take a complimentary Learning@Cisco Self-Assessment and learn
> about Cisco certifications, training, and career opportunities.
> http://p.sf.net/sfu/cisco-dev2dev
> _______________________________________________
> Jump-pilot-devel mailing list
> Jump-pilot-devel@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

------------------------------------------------------------------------------
The demand for IT networking professionals continues to grow, and the
demand for specialized networking skills is growing even more rapidly.
Take a complimentary Learning@Cisco Self-Assessment and learn 
about Cisco certifications, training, and career opportunities. 
http://p.sf.net/sfu/cisco-dev2dev
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to