Commit graph

29 commits

Author SHA1 Message Date
Mark Langen
321f5597b7 Change main client window MagePanes from JInternalFrames to JLayeredPanes
* This change's purpose is to get rid of the extra borders shown around the window border. These arise from using JInternalFrames in a JDestopPane and are impossible to remove in a forwards compatible way when using JInternalFrames. The solution it to move to have MagePane inherit from a plain old JLayeredPane instead of JInternalFrame. All of the MagePanes are always maximized anyways, so this doesn't lose any functionality.
2017-04-07 22:08:13 -06:00
vraskulin
076840df53 Big refactoring
I used Intellij IDEA to automatically refactor code to achive 3 goals.
1) get rid of anonymouse classes, and replace the with lamba to get more readeable and clean code (like in TableWaitingDialog).
2) make effectively final  variables actually final to avoid inadvertent changes on it in further releases and keep objects as immutable, as possible.
3)  Get rid of unused imports (most of the changes) in whole project classes.
2017-01-09 19:16:53 +03:00
draxdyn
a7409f3d08 Hold priority on Ctrl+click
In most cases, it is not useful to hold priority after doing something,
since the spell or ability added to the stack can just be performed
beforehand.

Hence, automatically passing priority is the only comfortable setting.

However, in some cases it is useful (chiefly for Infernal Tutor +
Lion's Eye Diamond and similar interaction), and currently players
have to open Preferences, change the option and then change it back
whenever they need to hold priority, which is very annoying.

This change allows to temporarily hold priority by simply holding
Control while performing an action, which solves the issue in a
manner similar to other clients.

A "Hold" indicator next to the spells cast indicator is displayed so
that the user knows his Control key holding was registered.

The code works by adding a new HOLD_PRIORITY player action that causes
the automatic priority pass options to be ignored until the player is
given priority again.

The client sends the message whenever it's not already holding priority
and Ctrl+click/space/enter happens anywhere.

This is somewhat "loose" as it means that Ctrl+click on the background
also holds priority, but this might actually be desirable and it greatly
simplifies the code, since only a global AWT event listener is required,
and there is no need to change every place in the code that could add
something to the stack.

It is also possible to hold priority and stop holding priority using
the context menu.
2016-06-29 19:57:45 +02:00
Kenny Wottrich
f3c83d54f5 Remove Unused Imports
Delete unused java imports that cause compiler warnings
2016-04-24 19:50:29 -05:00
LevelX2
7ef0a0a7f0 Some more changes to GUI to better support high screen resolutions. 2016-02-13 02:30:05 +01:00
LevelX2
706d319f81 Some more changes to GUI to better support high screen resolutions. 2016-02-12 13:35:04 +01:00
LevelX2
5b02b5b32c Exile, Reveal, Looked At windows of a game are hidden now as you switch to another pane (e.g. other game, tables, deck editor) and shown again as you switch back. 2015-06-23 16:14:11 +02:00
LevelX2
30869beca0 * Some changes to game start logic (better handling for disconnected users). Changes to server logging. 2014-12-08 01:30:18 +01:00
LevelX2
6c6d12f40f * Fixed that game name for menu works also for watching games. 2014-06-25 12:28:43 +02:00
LevelX2
eb1e8dda14 * Client Windows - Name of game in windows sub menu is now build with player names. 2014-06-25 01:32:55 +02:00
LevelX2
753ada0a01 * Fixed a cleanup problem that locked the game at game end. Minor formattings and cleanup additions. 2014-02-11 00:38:10 +01:00
LevelX2
0a18a7bea6 Removed majority of memory leaks from game / editor / dialog handling. 2014-02-02 21:57:02 +01:00
LevelX2
dda33f86a4 Removed more memory leaks in game and editor panes and panels of client. 2014-02-01 18:15:42 +01:00
LevelX2
30ddcaf99b Some changes to reduce memory leaks. 2014-01-31 15:08:40 +01:00
LevelX2
e2c0e211ef More changes to reduce memory leaks. 2014-01-31 08:22:47 +01:00
LevelX2
da2dc4cd5a Some changes to prevent memory leaks from gamePane (not fiished yet). 2014-01-30 17:35:12 +01:00
magenoxx
ec5b5845ef Fixed Issue#84: Arrows that show the targets are always on top 2013-01-08 15:58:48 +04:00
North
239a4fb100 [refactoring][minor] Replaced all tabs with four spaces. 2012-06-19 23:50:20 +03:00
BetaSteward
b975d98bf5 partial fix for issue 81 2011-11-21 08:29:21 -05:00
magenoxx
cc5a76e62b Finished ability picker. +even dispatching. +fixed bug in horizontal scrool bar. 2011-07-16 12:17:22 +04:00
magenoxx
616aea619d New ability picker (though not turned on yet) 2011-07-15 17:27:22 +04:00
BetaSteward
2ff280caa7 fixed bug when switching from game to another pane 2011-06-07 23:26:04 -04:00
BetaSteward
d8fca737fd added some client window management + suppress calls when TablesPane is not visible 2011-06-07 22:32:58 -04:00
BetaSteward
94c5a0cdfb client + server improvements 2011-05-17 21:55:20 -04:00
BetaSteward
2f515e242b fixed Issue 64 2011-05-09 22:58:40 -04:00
BetaSteward
4f06f78621 UI fixes - can now play simultaneous games 2011-03-04 22:46:56 -05:00
BetaSteward
812d1bc9c3 added Windows button to toolbar 2011-01-24 22:35:07 -05:00
BetaSteward
e460b9af20 fixed some match problems 2010-12-29 15:00:18 -05:00
magenoxx
f775f7c511 Moved /src and /resources to maven stardard /src/main/java and /src/main/resources. Hope it's ok, if not I'll revert. 2010-10-22 12:40:50 +00:00
Renamed from Mage.Client/src/mage/client/game/GamePane.java (Browse further)