mirror of
https://github.com/oliverschmidt/contiki.git
synced 2024-11-03 22:06:22 +00:00
if newly started plugin has not specified a location/size, use defaults
This commit is contained in:
parent
4f5ff657d4
commit
e26d2b596f
@ -24,7 +24,7 @@
|
|||||||
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
|
||||||
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
* SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||||
*
|
*
|
||||||
* $Id: GUI.java,v 1.85 2008/10/03 13:40:56 fros4943 Exp $
|
* $Id: GUI.java,v 1.86 2008/10/03 14:31:32 fros4943 Exp $
|
||||||
*/
|
*/
|
||||||
|
|
||||||
package se.sics.cooja;
|
package se.sics.cooja;
|
||||||
@ -1612,12 +1612,14 @@ public class GUI extends Observable {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// Set location if not already visible
|
// Set location if not already visible
|
||||||
if (!plugin.isVisible()) {
|
if (plugin.getLocation().x <= 0 && plugin.getLocation().y <= 0) {
|
||||||
plugin.setLocation((nrFrames + 1) * FRAME_NEW_OFFSET, (nrFrames + 1)
|
plugin.setLocation(
|
||||||
* FRAME_NEW_OFFSET);
|
nrFrames * FRAME_NEW_OFFSET,
|
||||||
plugin.setVisible(true);
|
nrFrames * FRAME_NEW_OFFSET);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
plugin.setVisible(true);
|
||||||
|
|
||||||
// Deselect all other plugins before selecting the new one
|
// Deselect all other plugins before selecting the new one
|
||||||
try {
|
try {
|
||||||
for (JInternalFrame existingPlugin : myDesktopPane.getAllFrames()) {
|
for (JInternalFrame existingPlugin : myDesktopPane.getAllFrames()) {
|
||||||
|
Loading…
Reference in New Issue
Block a user