On 06.04.2018 13:38, Michaël Michaud wrote:
> Hi Ede,
> 
> Does it really work for you ? It is strange. 

jupp, works

>My second screen is off and I did not think there is something related to dual 
>screen.

what's java version that fails, maybe it's a java bug? mine is java8u152 x64 
currently

> Teh stack trace is as follow :
> 
> java.lang.NullPointerException
>     at 
> java.desktop/javax.swing.SwingUtilities.convertPointFromScreen(SwingUtilities.java:480)
>     at 
> com.vividsolutions.jump.workbench.ui.GUIUtil.setBounds(GUIUtil.java:1352)
>     at 
> com.vividsolutions.jump.workbench.ui.WorkbenchFrame.position(WorkbenchFrame.java:1695)
>     at 
> com.vividsolutions.jump.workbench.ui.WorkbenchFrame.addInternalFrame(WorkbenchFrame.java:975)
>     at 
> org.openjump.core.ui.plugin.layer.NewLayerPropertiesPlugIn.execute(NewLayerPropertiesPlugIn.java:267)

looks like java9 to me "java.desktop/javax.swing.SwingUtilities"

let me try that.

..ede

> Michaël
> 
> 
> Le 06/04/2018 à 11:32, edgar.sol...@web.de a écrit :
>> hey Mike,
>>
>> just tried "layer context menu -> layer properties" and that works for me. 
>> maybe this is different on a two screen system which i do not have set up 
>> right now.
>>
>> could you please try and send the stack if you can still reproduce it?
>>
>> ..ede
>>
>> On 05.04.2018 22:25, Michaël Michaud wrote:
>>> Hi Ede,
>>>
>>> The piece of code you commented was the only solution I found to fix the 
>>> NPE arising during opening of the DetachableInternalFrame created by 
>>> NewLayerProperties (layer contextual menu).
>>>
>>> However, this is just a workaround. I first thought the internal frame was 
>>> missing a parent,
>>> but it is added to the WorkbenchFrame the same way as, for example, 
>>> ViewAttributesFrame in ViewAttributePlugIn :
>>>
>>> context.getWorkbenchFrame().addInternalFrame(JInternalFrame, boolean, 
>>> boolean);
>>>
>>> So I don't know why adding this particular internal frame is throwing a NPE.
>>>
>>> If you find the proper way to fix NewLayerProperties, you're welcome, in 
>>> the meantime, your improvment in the task frames placement will 
>>> re-introduce this NPE.
>>>
>>> Michaël
>>>
>>>
>>> Le 05/04/2018 à 16:11, edgar.sol...@web.de a écrit :
>>>> hey Mike,
>>>>
>>>> i noticed that task frames were not properly placed into top left corner 
>>>> of the desktop pane but with some offset from the top. commenting the 
>>>> below change of you multi screen fix seems to resolve the issue.
>>>>
>>>> can you double check how or if the below was needed or can be removed?
>>>>
>>>> thx.. ede
>>>>
>>>>
>>>> -------- Forwarded Message --------
>>>> Subject: [JPP-Devel] SVN: [5734] 
>>>> core/trunk/src/com/vividsolutions/jump/workbench/ui/ GUIUtil.java
>>>> Date: Thu, 05 Apr 2018 14:08:31 +0000
>>>> From: jump-pilot-svn--- via Jump-pilot-devel 
>>>> <jump-pilot-devel@lists.sourceforge.net>
>>>> Reply-To: OpenJump develop and use <jump-pilot-devel@lists.sourceforge.net>
>>>> To: jump-pilot-devel@lists.sourceforge.net
>>>> CC: jump-pilot-...@lists.sourceforge.net
>>>>
>>>> Revision: 5734
>>>>            http://sourceforge.net/p/jump-pilot/code/5734
>>>> Author:   edso
>>>> Date:     2018-04-05 14:08:31 +0000 (Thu, 05 Apr 2018)
>>>> Log Message:
>>>> -----------
>>>> fix TaskFra mes bot placed properly into left upper corner of desktop pane
>>>>
>>>> Modified Paths:
>>>> --------------
>>>>      core/trunk/src/com/vividsolutions/jump/workbench/ui/GUIUtil.java
>>>>
>>>> Modified: core/trunk/src/com/vividsolutions/jump/workbench/ui/GUIUtil.java
>>>> ===================================================================
>>>> --- core/trunk/src/com/vividsolutions/jump/workbench/ui/GUIUtil.java    
>>>> 2018-04-05 13:26:30 UTC (rev 5733)
>>>> +++ core/trunk/src/com/vividsolutions/jump/workbench/ui/GUIUtil.java    
>>>> 2018-04-05 14:08:31 UTC (rev 5734)
>>>> @@ -1348,7 +1348,7 @@
>>>>           (int) other.getLocationOnScreen().getY()
>>>>               + (location.fromBottom ? (other.getHeight()
>>>>                   - componentToMove.getHeight() - location.y) : 
>>>> location.y));
>>>> -    if (!(componentToMove instanceof Window) && !(componentToMove 
>>>> instanceof JInternalFrame)) {
>>>> +    if (!(componentToMove instanceof Window) /*&& !(componentToMove 
>>>> instanceof JInternalFrame) */) {
>>>>         SwingUtilities.convertPointFromScreen(p, 
>>>> componentToMove.getParent());
>>>>       }
>>>>       componentToMove.setBounds(p.x, p.y, width, height);
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Check out the vibrant tech community on one of the world's most
>>>> engaging tech sites, Slashdot.org! http://sdm.link/slashdot
>>>> _______________________________________________
>>>> Jump-pilot-devel mailing list
>>>> Jump-pilot-devel@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel
>>>>
>>
> 


------------------------------------------------------------------------------
Check out the vibrant tech community on one of the world's most
engaging tech sites, Slashdot.org! http://sdm.link/slashdot
_______________________________________________
Jump-pilot-devel mailing list
Jump-pilot-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jump-pilot-devel

Reply via email to