<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0"
    xmlns:content="http://purl.org/rss/1.0/modules/content/"
    xmlns:wfw="http://wellformedweb.org/CommentAPI/"
    xmlns:dc="http://purl.org/dc/elements/1.1/"
>
<!-- MHonArc v2.6.10 -->
	<channel>
		<title>news.eclipse.technology.albireo</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/maillist.html</link>
		<description>NewsGroup: news.eclipse.technology.albireo</description>
		<language>en-us</language>
		<pubDate>Tue, 23 Jun 2009 23:59:59 GMT</pubDate>
		<lastBuildDate>Tue, 23 Jun 2009 23:59:59 GMT</lastBuildDate>
		<docs>http://blogs.law.harvard.edu/tech/rss</docs>
		<generator>MHonArc RSS 2.0 RCFile</generator>
		<managingEditor>webmaster@eclipse.org (Webmaster)</managingEditor>
		<webMaster>webmaster@eclipse.org (Webmaster)</webMaster>
		<image>
			<title>news.eclipse.technology.albireo</title>
			<url>http://www.eclipse.org/eclipse.org-common/themes/Phoenix/images/eclipse_home_header.jpg</url>
			<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/maillist.html</link>
		</image>
 

	<item>
		<title>[news.eclipse.technology.albireo] Re: More tips for the sample code</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00117.html</link>
		<description>Gordon - has this fix been applied to 0.0.3? I took a look, but it seems like things have changed a lot and I was not able to identify if these changes are in the latest release. Or are they no longer even necessary? Thanks! - Ken &amp;quot;Gordon Hirsch&amp;quot; &amp;lt;gordon.h...</description>
		<content:encoded><![CDATA[<tt>Gordon - has this fix been applied to 0.0.3? I took a look, but it seems 
like things have changed a lot and I was not able to identify if these 
changes are in the latest release. Or are they no longer even necessary?</tt><br>
<br>
<pre style="margin: 0em;">Thanks!</pre><br>
<pre style="margin: 0em;">- Ken</pre><br>
<tt>&quot;Gordon Hirsch&quot; &lt;gordon.hirsch@xxxxxxx&gt; wrote in message 
<a  href="news:fdh53e$j7i$1@xxxxxxxxxxxxxxxxxxxx">news:fdh53e$j7i$1@xxxxxxxxxxxxxxxxxxxx</a>
</tt><blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><tt>James wrote:
</tt><blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><tt>I have found several more issues relating to focus and the SWT/Swing<br>
integration.  I have breifly outlined each issue below and posted my code<br>
modifications at the bottom.  I suspect I may not be clear enough in<br>
describing both the issues, the solutions, and how they work, so please 
ask<br>
any questions you might have.  I would imagine others have periodically<br>
noticed at least some of these issues as well.</tt><br>
<br>
<tt>Any thoughts on these Gordon?
</tt></blockquote><tt><br>James, first of all, thank you for sharing your fixes and improvements. I 
have some comments and questions below.</tt><br>
<br>
<blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;"><br>My workarounds affect EmbeddedSwingComposite, SwtFocusHandler, and
AwtFocusHandler classes.</pre><br>
<tt>The issues:<br>
#1<br>
When using keyboard navigation, the default code misses sending the focus 
to<br>
the AWT control on its first pass through (the returned focus component 
is<br>
null).  This can be solved by setting awtHasFocus to true at the top of 
the<br>
gainFocus method instead of at the bottom.  This will ensure that an 
attempt<br>
is made to find a focusable swing control on the first focus attempt.
</tt></blockquote><tt><br>Yes, this is definitely a bug in the article. Another solution is to 
change the EmbeddedChildFocusTraversalPolicy.getCurrentComponent() method 
to call super.getDefaultComponent, rather than this.getDefaultComponent.</tt><br>
<br>
<blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><tt><br>#2<br>
I use an EmbeddedSwingComponent as the full contents of an editor<br>
(consequently, the IWorkbenchPart's setFocus method sets the focus to the<br>
EmbeddedSwingComponent).  When issue #1 is fixed (ie, the AWT control<br>
automatically gets the focus when the SWT control gets the focus), there 
is<br>
occasionally a deadlock in Java 1.6 when several editors are opened at 
once<br>
(even though only asycExec and invokeLater calls are used).  The deadlock 
is<br>
happening way down in AWT Code in the WPanelPeer class and is triggered 
by<br>
the component.requestFocus inside of the awtHandler's gainFocus method.<br>
This seems to be solved when issue #3 is solved.
</tt></blockquote><tt><br>It's now pretty clear that Component.requestFocus has to be used carefully 
to avoid deadlock (and in our case other problems). The main thing is to 
make sure that it is always called from the AWT event thread. 
Unfortunately, the article code calls it from the SWT thread in two 
places. For example, I've now re-implemented 
EmbeddedSwingComposite.setFocus()  as follows:</tt><br>
<br>
<pre style="margin: 0em;">    public boolean setFocus() {
        checkWidget();</pre><br>
<tt>        //if (!isFocusable()) {<br>
        //    return false;<br>
        //}<br>
        if (swtHandler != null) {<br>
            // Setting focus on the embedded component must posted to the<br>
            // AWT thread because:<br>
            // 1) The AWT Component.requestFocus method can deadlock if<br>
            //    called simultaneously from different threads.<br>
            // 2) The embedded component is created asynhronously (on the<br>
            //    AWT thread), so it may not exist yet.<br>
            // The call below does the appropriate posting. Since it is 
done<br>
            // asynchronously, it is impossible to know the result, so<br>
            // always return true.<br>
            swtHandler.transferFocusToAwt();<br>
            return true;<br>
        } else {<br>
            return super.setFocus();<br>
        }<br>
    }</tt><br>
<br>
<pre style="margin: 0em;">transferFocusToAwt is what you would expect:</pre><br>
<pre style="margin: 0em;">    void transferFocusToAwt() {
        EventQueue.invokeLater(new Runnable() {
            public void run() {
                awtHandler.gainFocus();
            }
        });
    }</pre><br>
<tt>A similar change is needed to the EmbeddedSwingComposite.forceFocus 
method.</tt><br>
<br>
<tt>I suspect these fixes will eliminate the deadlock problem you saw and that 
your solution to #3, though useful in its own right, simply made the 
deadlock less likely.</tt><br>
<br>
<blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><tt><br>#3<br>
When the EmbeddedSwingComponent is the only focusable component inside of 
a<br>
Tab Folder, the awtHandler.gainFocus call causes a malfunction in 
keyboard<br>
navigation.  When the tab labels get the focus (a tab's label is<br>
underlined), typically one can switch between tabs by using the arrow 
keys<br>
and then dive into the current tab using the 'tab' key.  To do this, the 
SWT<br>
Tab Folder seems to momentarily set the focus to the tab's contents and 
then<br>
return focus to the tab label.</tt><br>
<br>
<tt>The problem is that we are telling AWT to take the focus when the tab's<br>
contents gets the focus, so the focus doesn't go back to tab's label.  I<br>
have added set/get AbortFocus methods to the SwtFocusHandler.  The abort<br>
focus value is set whenever the SWT Control's focus is gained or lost. 
This<br>
way if the SWT control loses focus before AWT has a chance to set its 
focus<br>
we can decide not to set the AWT focus.</tt><br>
<br>
<tt>I suspect the deadlock also has something to do with this quick transfer 
of<br>
focus.
</tt></blockquote><tt><br>I didn't know you could navigate this way, so it clearly wasn't tested 
:-). Your solution looks like a good one.</tt><br>
<br>
<blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><tt><br>#4<br>
There is a memory leak when you dispose of the SWT Control even if you 
set<br>
the frame to null.  This leak is present in Java 1.5 update 11 and Java 
1.6.<br>
To remove the memory leak, the frame needs to have its 
FocusableWindowState<br>
set to false and it should be disposed of when the EmbeddedSwingComponent 
is<br>
disposed of.  The frame should be disposed of in the Swing EDT.
</tt></blockquote><tt><br>Interesting. SWT_AWT.new_Frame() installs a listener that is supposed to 
dispose the frame (on the AWT event thread) when the composite is 
disposed. Any ideas on why this is not happening?</tt><br>
<br>
<pre style="margin: 0em;">Is the need to set FocusableWindowState to false maybe due to this bug?</pre><br>
<pre style="margin: 0em;"><a  href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6469530">http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6469530</a>.</pre><br>
<tt>Or something else? I'm wondering if there's something that needs to be 
reported to Sun...</tt><br>
<br>
<tt>I ran into a similar leak that was triggered by adding components to the 
frame from outside the AWT EDT. See 
<a  href="http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6411042">http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6411042</a>.</tt><br>
<br>
</blockquote><pre style="margin: 0em;"><br></pre><br>
]]></content:encoded>
		<pubDate>Tue, 23 Jun 2009 23:46:45 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00117.html</guid>
		<author>kennyp@xxxxxxx (Kenny Prole)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Re: Drag and drop and cut, copy,	paste between awt / swing and swt.</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00116.html</link>
		<description>I'm stuck on this too! If anyone has any information about how to resolve the incompatibility between custom SWT ByteArrayTransfer and custom Swing DataFlavors, please help us out? My am required to provide a solution to this very soon and unfortunately I'...</description>
		<content:encoded><![CDATA[<tt>I'm stuck on this too! If anyone has any information about how to resolve 
the incompatibility between custom SWT ByteArrayTransfer and custom Swing 
DataFlavors, please help us out? My am required to provide a solution to 
this very soon and unfortunately I'm also stuck! It's just so tricky to 
debug because it either all works or it doesn't... I just keep getting 
java.awt.datatransfer.UnsupportedFlavorException also.</tt><br>
<br>
<tt>Does anyone have a code snippet on how to do this, or know how to declare 
a DataFlavor to be compatible with a custom SWT ByteArrayTransfer type? It 
sounds like this is causing more than a few people some grief.</tt><br>
<br>
<pre style="margin: 0em;">Help, please, anyone!</pre><br>
<pre style="margin: 0em;">Chris.</pre><br>
<pre style="margin: 0em;"><br></pre><br>
]]></content:encoded>
		<pubDate>Sun, 14 Jun 2009 10:28:00 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00116.html</guid>
		<author>duval_1977@xxxxxxx (Chris )</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Re: Drag and drop and cut, copy,	paste between awt / swing and swt.</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00115.html</link>
		<description>I'm delighted that it's possible... If you can offer any crumbs of advice that would be wonderful because it seems that our project, and perhaps a few other perople's projects, are languishing with the lack of support. We are dying here... </description>
		<content:encoded><![CDATA[<tt>I'm delighted that it's possible... If you can offer any crumbs of advice 
that would be wonderful because it seems that our project, and perhaps a 
few other perople's projects, are languishing with the lack of support.  
We are dying here...</tt><br>
<br>
<br>
]]></content:encoded>
		<pubDate>Wed, 10 Jun 2009 09:47:32 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00115.html</guid>
		<author>greg.pirsig@xxxxxxx (Greg Pirsig)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Restoring the active shell in	SwtInputBlocker does not work properly</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00114.html</link>
		<description>If the SwtInputBlocker is used for a modal awt dialog it tries to restore the last active shell when the awt dialog closes. This is done because windows from other applications could be openeded during SWT was being blocked (SwtInputBlocker line 116). When...</description>
		<content:encoded><![CDATA[<tt>If the SwtInputBlocker is used for a modal awt dialog it tries to restore 
the last active shell when the awt dialog closes. This is done because 
windows from other applications could be openeded during SWT was being 
blocked (SwtInputBlocker line 116).</tt><br>
<br>
<tt>When the method block(AwtDialogListener dialogListener) is called the 
SwtInputBlocker tries to remember the active shell. This fails because 
display.getActiveShell() does mostly return null. In this case the first 
shell will be taken from the display. If you work with more than 1 shell 
at the same time and you open/close a swing dialog, always the first shell 
from the display gets the focus not the original parent.</tt><br>
<br>
<tt>I added a SWT.Activate listener to the display in the AwtDialogListener to 
remember the last active shell. Any better solutions?</tt><br>
<br>
<tt>Another problem is if you start a complete new awt window, lets say for 
JasperReports, from a swt context and open a new awt modal dialog from 
there, if you close the awt dialog the swt shell gets the focus not the 
awt window from JasperReports which was the parent.</tt><br>
<br>
<pre style="margin: 0em;">Regards
Dominik</pre><br>
<br>
]]></content:encoded>
		<pubDate>Tue, 26 May 2009 14:46:53 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00114.html</guid>
		<author>dominik.kaspar@xxxxxxx (Dominik Kaspar)</author>
	</item>
	<item>
		<title>[news.eclipse.technology.albireo] JComboBox Focus Problem</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00113.html</link>
		<description>If a JComboBox is used in a second swt shell embedded into a SwingControl and the JComobBox is using a javax.swing.Popup$HeavyWeightWindow, this popup window will be moved on top of the primary shell while the second shell (including the rest of the JCombo...</description>
		<content:encoded><![CDATA[<tt>If a JComboBox is used in a second swt shell embedded into a SwingControl 
and the JComobBox is using a javax.swing.Popup$HeavyWeightWindow, this 
popup window will be moved on top of the primary shell while the second 
shell (including the rest of the JComboBox) will be moved in the 
background. This only occures if the popup of the JComboBox will be 
openend the second time.</tt><br>
<br>
<tt>To quick fix this problem I added following to the method 
handleOpenedWindow(WindowEvent event) in the class AwtDialogListener:<br>
..<br>
if 
(window.getClass().getName().equals(&quot;javax.swing.Popup$HeavyWeightWindow&quot;)) 
{<br>
 try {<br>
   window.setAlwaysOnTop(false);<br>
 } catch (SecurityException se) {<br>
   // setAlwaysOnTop is restricted,<br>
   // the exception is ignored<br>
 }<br>
}<br>
..</tt><br>
<br>
<br>
]]></content:encoded>
		<pubDate>Tue, 26 May 2009 14:17:32 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00113.html</guid>
		<author>dominik.kaspar@xxxxxxx (Dominik Kaspar)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Memory leak</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00112.html</link>
		<description>Hi I am using SwingControl on a page of a multi page editor in a RCP application. I noticed that the Control derived from SwingControl is NOT garbage collected. The result is that the user has to stop the application after a certain time because it consume...</description>
		<content:encoded><![CDATA[<pre>Hi

I am using SwingControl on a page of a multi page editor in a RCP 
application. I noticed that the Control derived from SwingControl is NOT 
garbage collected. The result is that the user has to stop the application 
after a certain time because it consumes to much memory. I reported already 
a bug (<a  href="https://bugs.eclipse.org/bugs/show_bug.cgi?id=275811">https://bugs.eclipse.org/bugs/show_bug.cgi?id=275811</a>) but got no 
answer.

I could find two problems in the implementation of SwingControl:
1. The method handleDispose is missing the code
      getShell().removeControlListener(shellControlListener);
2. The method addRootPaneContainer contains the line
      frame.add(applet);
   This line contains the reason why the the instance of MySwingComposite 
will
not be garbage collected. Unfortunately i was not able to find a fix for 
this
problem yet. (I commented this line temporarily out and then, together with 
the
change in the handleDispose method the garbage collector was able to remove 
the
instance of MySwingComposite from the heap!)

Anybody an idea why the frame can not be garbage collected as soon as the 
applet has been added to it?

Thanks
Reto



</pre>]]></content:encoded>
		<pubDate>Mon, 25 May 2009 07:43:02 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00112.html</guid>
		<author>reto.urfer@xxxxxxx (Eclipse Newsgroups)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Re: Size-Calculation of Embedded	Swing Controls in Dialogs</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00111.html</link>
		<description>I solved the problem by adding a SizeListener to the SwingControl which is called after the Swing/AWT size calculation is finished. There I just set the size on the shell again. It's a little bit ugly here that you can see the shell resizing on the screen....</description>
		<content:encoded><![CDATA[<tt>I solved the problem by adding a SizeListener to the SwingControl which is 
called after the Swing/AWT size calculation is finished. There I just set 
the size on the shell again. It's a little bit ugly here that you can see 
the shell resizing on the screen. I tried to set an initial size of 
Point(0,0) but the shell has some min size for the title and close, min, 
max buttons. Any ideas?</tt><br>
<br>
<pre style="margin: 0em;">Thanks and regards
Dominik</pre><br>
<pre style="margin: 0em;">Example code:</pre><br>
<pre style="margin: 0em;">TitleAreaDialog d = new TitleAreaDialog(topLevelShell) {
protected Control createDialogArea(final Composite parent) {
  Composite comp = (Composite) super.createDialogArea(parent);
  SwingControl control = new SwingControl(comp, SWT.NONE) {
    protected JComponent createSwingComponent() {
      JPanel p = new JPanel();
      p.setLayout(new java.awt.GridLayout(10, 1));
      for (int i = 0; i &lt; 10; i++) {
        p.add(new JTextField(String.valueOf(i)));
      }
      JScrollPane scroll = new JScrollPane(p);
      scroll.setBorder(new EmptyBorder(0, 0, 0, 0));
      return scroll;
    }
    public Composite getLayoutAncestor() {
      return parent;
    }
  };
  control.setLayoutData(new GridData(GridData.FILL_BOTH));
  control.addSizeListener(new SizeListener() {
    private boolean packed = false;
    public void preferredSizeChanged(SizeEvent event) {
      if (!packed) {
        Point size = getInitialSize();
        getShell().setSize(size);
        packed = true;
      }
    }
  });
  return parent;
}
};
d.open();</pre><br>
<br>
]]></content:encoded>
		<pubDate>Thu, 14 May 2009 09:33:30 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00111.html</guid>
		<author>dominik.kaspar@xxxxxxx (Dominik Kaspar)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Re: Drag and drop and cut, copy,	paste between awt / swing and swt.</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00110.html</link>
		<description> </description>
		<content:encoded><![CDATA[<tt>While I don't have a snippet or example I can post, I can say we have 
done this using both FileTransfer and ByteArrayTransfer so it is possible.</tt><br>
<br>
<tt>Tom Schindl wrote:
</tt><blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">Maybe asking the albireo guys?</pre><br>
<pre style="margin: 0em;">Tom</pre><br>
<tt>Grant Gayed schrieb:
</tt><blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">Hi Greg,</pre><br>
<pre style="margin: 0em;">I've asked someone here about this, and though we've never tried this, the
belief is that it should be possible.  On the swt side you subclass
ByteArrayTransfer, and on the awt/swing side you have a custom data flavor.
The part that's less clear (though may be trivial to someone that uses
awt/string reguarly) is how to specify the data type name on the awt/swing
side, because the awt/swing DataFlavors are keyed by mimeType, which I think
!= the data type name on the swt side.  Looking at the javadoc pages,
SystemFlavorMap looks like it could be useful for doing this mapping.</pre><br>
<pre style="margin: 0em;">Sorry if this answer isn't definitive enough, I was hoping that someone else
had more concrete experience with this (the awt/swing side in particular).
I plan to investigate this when I have more time and will post an example
snippet if successful, but for the next while we're winding down the eclipse
3.5 work, so I'm not sure when this will be.  (If anyone else has an example
of this then please submit it!).</pre><br>
<pre style="margin: 0em;">Grant</pre><br>
<pre style="margin: 0em;"><br>&quot;Greg Pirsig&quot; &lt;greg.pirsig@xxxxxxxxx&gt; wrote in message
<a  href="news:80422c4a99c27545a8814a26dd94a875$1@xxxxxxxxxxxxxxxxxx">news:80422c4a99c27545a8814a26dd94a875$1@xxxxxxxxxxxxxxxxxx</a>
</pre><blockquote style="border-left: #5555EE solid 0.2em; margin: 0em; padding-left: 0.85em"><pre style="margin: 0em;">Greetings all!</pre><br>
<pre style="margin: 0em;">My Project Team and I are evaluating different Rich Client Platforms
that we can use with out next integration project.  I don't need
anything too fancy, but I will need to incorporate some existing swing
controls (NASA's World Wind etc) and will need to support cut, copy,
paste and drag and drop of custom objects between awt / swing and swt.
After reading ali's harrowing journey that seemed to end in defeat
(search for &quot;Drag and drop from SWT to Swing with a custom
ByteArrayTransfer&quot;), I&#xC3;&#xEF;d like to clarify if this is a reasonable
expectation.  Does the Eclipse rcp support custom transfer types between
swt and awt / swing?  Does it work? Has anyone gotten this to work or
should I just stick to swing?</pre><br>
<pre style="margin: 0em;">Thanks</pre><br>
<pre style="margin: 0em;">Greg Pirsig.</pre><br>
<pre style="margin: 0em;">P.S. I've already added this issue to the RCP newsgroup, but without any
luck so far. I hope no one minds me adding it here too in an attempt to
seek out anyone who can help... also please let me know if there is a
better place or another website that I should be asking such questions?</pre><br>
</blockquote><br>
</blockquote></blockquote><br>
]]></content:encoded>
		<pubDate>Tue, 05 May 2009 01:34:08 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00110.html</guid>
		<author>stephan.nagy@xxxxxxx (Stephan Nagy)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Re: Drag and drop and cut, copy,	paste between awt / swing and swt.</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00109.html</link>
		<description>Maybe asking the albireo guys? Tom Grant Gayed schrieb: </description>
		<content:encoded><![CDATA[<pre>Maybe asking the albireo guys?

Tom

Grant Gayed schrieb:
&gt; Hi Greg,
&gt; 
&gt; I've asked someone here about this, and though we've never tried this, the
&gt; belief is that it should be possible.  On the swt side you subclass
&gt; ByteArrayTransfer, and on the awt/swing side you have a custom data flavor.
&gt; The part that's less clear (though may be trivial to someone that uses
&gt; awt/string reguarly) is how to specify the data type name on the awt/swing
&gt; side, because the awt/swing DataFlavors are keyed by mimeType, which I think
&gt; != the data type name on the swt side.  Looking at the javadoc pages,
&gt; SystemFlavorMap looks like it could be useful for doing this mapping.
&gt; 
&gt; Sorry if this answer isn't definitive enough, I was hoping that someone else
&gt; had more concrete experience with this (the awt/swing side in particular).
&gt; I plan to investigate this when I have more time and will post an example
&gt; snippet if successful, but for the next while we're winding down the eclipse
&gt; 3.5 work, so I'm not sure when this will be.  (If anyone else has an example
&gt; of this then please submit it!).
&gt; 
&gt; Grant
&gt; 
&gt; 
&gt; &quot;Greg Pirsig&quot; &lt;greg.pirsig@xxxxxxxxx&gt; wrote in message
&gt; <a  href="news:80422c4a99c27545a8814a26dd94a875$1@xxxxxxxxxxxxxxxxxx">news:80422c4a99c27545a8814a26dd94a875$1@xxxxxxxxxxxxxxxxxx</a>
&gt;&gt; Greetings all!
&gt;&gt;
&gt;&gt; My Project Team and I are evaluating different Rich Client Platforms
&gt;&gt; that we can use with out next integration project.  I don't need
&gt;&gt; anything too fancy, but I will need to incorporate some existing swing
&gt;&gt; controls (NASA's World Wind etc) and will need to support cut, copy,
&gt;&gt; paste and drag and drop of custom objects between awt / swing and swt.
&gt;&gt; After reading ali's harrowing journey that seemed to end in defeat
&gt;&gt; (search for &quot;Drag and drop from SWT to Swing with a custom
&gt;&gt; ByteArrayTransfer&quot;), I&#xC3;&#xEF;d like to clarify if this is a reasonable
&gt;&gt; expectation.  Does the Eclipse rcp support custom transfer types between
&gt;&gt; swt and awt / swing?  Does it work? Has anyone gotten this to work or
&gt;&gt; should I just stick to swing?
&gt;&gt;
&gt;&gt; Thanks
&gt;&gt;
&gt;&gt; Greg Pirsig.
&gt;&gt;
&gt;&gt; P.S. I've already added this issue to the RCP newsgroup, but without any
&gt;&gt; luck so far. I hope no one minds me adding it here too in an attempt to
&gt;&gt; seek out anyone who can help... also please let me know if there is a
&gt;&gt; better place or another website that I should be asking such questions?
&gt;&gt;
&gt; 
&gt; 

</pre>]]></content:encoded>
		<pubDate>Tue, 28 Apr 2009 15:07:44 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00109.html</guid>
		<author>tom.schindl@xxxxxxx (Tom Schindl)</author>
	</item>


	<item>
		<title>[news.eclipse.technology.albireo] Re: Size-Calculation of Embedded	Swing Controls in Dialogs</title>
		<link>http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00108.html</link>
		<description>The first solution is not a option because we use a xml to generate the swing components. To pre calculate the size of the components will be a lot of effort. Therefore I tried to put my swing components into a frame (without displaying it), pack the compo...</description>
		<content:encoded><![CDATA[<tt>The first solution is not a option because we use a xml to generate the 
swing components. To pre calculate the size of the components will be a 
lot of effort. Therefore I tried to put my swing components into a frame 
(without displaying it), pack the components, get the size and remove the 
components from the frame. Unfortunatly I had to do this in the SWT thread 
before the Swing thread is used for really creating the components. You 
can imagine that this leads into problems;) Is it possible to put the 
'swing pre creation and packing' into a sync swing thread?</tt><br>
<br>
<tt>The second solution could be a work around. The problem there is that you 
can see the dialog, when it pupups, in the wrong size for a short moment 
before it resizes to the correct size. The problem here is really to find 
the correct moment to set the size and I don't know how to figure out when 
the size calculation of the swing componetns is successfully finished.</tt><br>
<br>
<pre style="margin: 0em;">Thanks, Dominik</pre><br>
<br>
]]></content:encoded>
		<pubDate>Tue, 14 Apr 2009 09:15:43 GMT</pubDate>
		<guid isPermaLink="true">http://dev.eclipse.org/mhonarc/newsLists/news.eclipse.technology.albireo/msg00108.html</guid>
		<author>dominik.kaspar@xxxxxxx (Dominik Kaspar)</author>
	</item>

 
	</channel>
	</rss>
<!-- MHonArc v2.6.10 -->
