contiki-os/contiki — pull request #639 by ejoerns (2014-04-14 22:48:08+00:00)
Title: [Cooja] Set location of newly created plugins relative to second last activated plugin

I felt very uncomfortable with the default plugin placement in Cooja.
It just counts the number of total frames on the desktop pane (including invisible ones!)
and computes the placement offset by that.

This is unflexible and for larger numbers of frames this might even result in opening new frames
below the currently visual area of the desktop pane.

So my approach for a (hopefully) slightly improved placement strategy is
to set the location of newly created plugins relative to the second last activated plugin.

For explanation, this tries to meet two requirements:

- Avoid covering the last activated plugin frame,
i.e. the one from that was active when new plugin
start was invoked.
- Set the new plugin near an actively used desktop pane
location and allow 'diagonal stacking'