Skip to content

Commit 5f38c4c

Browse files
committed
1.0.1.8 hotfix release commit
1 parent f307889 commit 5f38c4c

File tree

12 files changed

+32
-37
lines changed

12 files changed

+32
-37
lines changed
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
package com.mercury.platform.core;
22

33
public class MercuryConstants {
4-
public static final String APP_VERSION = "1.0.1.8.0";
4+
public static final String APP_VERSION = "1.0.1.8.1";
55
public static final String SERVER_HOST = "exslims.ddns.net";
66
public static final int PORT = 5555;
77
}

app-core/src/main/java/com/mercury/platform/shared/config/configration/impl/HotKeyConfigurationService.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -43,7 +43,7 @@ public HotKeysSettingsDescriptor getDefault() {
4343
scannerNDataList.add(new HotKeyPair(HotKeyType.N_CLOSE_NOTIFICATION,new HotKeyDescriptor("F6",NativeKeyEvent.VC_F6,false,false,false)));
4444

4545
List<HotKeyPair> taskBarNDataList = new ArrayList<>();
46-
taskBarNDataList.add(new HotKeyPair(HotKeyType.T_TO_HIDEOUT,new HotKeyDescriptor("F1",NativeKeyEvent.VC_F1,false,false,false)));
46+
taskBarNDataList.add(new HotKeyPair(HotKeyType.T_TO_HIDEOUT,new HotKeyDescriptor("F10",NativeKeyEvent.VC_F10,false,false,false)));
4747
// taskBarNDataList.add(new HotKeyPair(HotKeyType.T_DND,new HotKeyDescriptor("F2",NativeKeyEvent.VC_F2,false,false,false)));
4848

4949
hotKeysSettingsDescriptor.setIncNHotKeysList(incNDataList);

app-ui/src/main/java/com/mercury/platform/ui/adr/components/AdrComponentsFactory.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -187,12 +187,12 @@ public void mousePressed(MouseEvent e) {
187187
MercuryStoreCore.hotKeySubject.subscribe(hotKey -> {
188188
if (allowed) {
189189
button.setBackground(AppThemeColor.BUTTON);
190-
if (hotKey.getVirtualKeyCode() == 27) {
190+
if (hotKey.getVirtualKeyCode() == 1) {
191191
descriptor.setHotKeyDescriptor(new HotKeyDescriptor());
192192
} else {
193193
descriptor.setHotKeyDescriptor(hotKey);
194194
}
195-
button.setText(hotKey.getTitle());
195+
button.setText(descriptor.getTitle());
196196
allowed = false;
197197
MercuryStoreUI.adrReloadSubject.onNext(descriptor);
198198
button.addMouseListener(mouseAdapter);

app-ui/src/main/java/com/mercury/platform/ui/components/panel/notification/IncomingNotificationPanel.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -108,6 +108,7 @@ private JPanel getHeader(){
108108
interactionPanel.add(openChatButton);
109109
interactionPanel.add(hideButton);
110110

111+
this.interactButtonMap.clear();
111112
this.interactButtonMap.put(HotKeyType.N_INVITE_PLAYER,inviteButton);
112113
this.interactButtonMap.put(HotKeyType.N_TRADE_PLAYER,tradeButton);
113114
this.interactButtonMap.put(HotKeyType.N_KICK_PLAYER,kickButton);
@@ -134,7 +135,9 @@ protected void updateHotKeyPool() {
134135
.stream()
135136
.filter(it -> it.getType().equals(type))
136137
.findAny().orElse(null);
137-
this.hotKeysPool.put(hotKeyPair.getDescriptor(),button);
138+
if(!hotKeyPair.getDescriptor().getTitle().equals("...")) {
139+
this.hotKeysPool.put(hotKeyPair.getDescriptor(), button);
140+
}
138141
});
139142
this.initResponseButtonsPanel();
140143
Window windowAncestor = SwingUtilities.getWindowAncestor(IncomingNotificationPanel.this);

app-ui/src/main/java/com/mercury/platform/ui/components/panel/notification/OutgoingNotificationPanel.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ private JPanel getHeader(){
7777
// interactionPanel.add(backToHo);
7878
interactionPanel.add(openChatButton);
7979
interactionPanel.add(hideButton);
80+
this.interactButtonMap.clear();
8081
this.interactButtonMap.put(HotKeyType.N_VISITE_HIDEOUT,visiteHideout);
8182
this.interactButtonMap.put(HotKeyType.N_TRADE_PLAYER,tradeButton);
8283
this.interactButtonMap.put(HotKeyType.N_LEAVE,leaveButton);
@@ -97,7 +98,9 @@ protected void updateHotKeyPool() {
9798
.stream()
9899
.filter(it -> it.getType().equals(type))
99100
.findAny().orElse(null);
100-
this.hotKeysPool.put(hotKeyPair.getDescriptor(),button);
101+
if(!hotKeyPair.getDescriptor().getTitle().equals("...")) {
102+
this.hotKeysPool.put(hotKeyPair.getDescriptor(), button);
103+
}
101104
});
102105
this.initResponseButtonPanel();
103106
Window windowAncestor = SwingUtilities.getWindowAncestor(OutgoingNotificationPanel.this);

app-ui/src/main/java/com/mercury/platform/ui/components/panel/notification/ScannerNotificationPanel.java

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -76,6 +76,7 @@ private JPanel getHeader(){
7676
interactionPanel.add(openChatButton);
7777
interactionPanel.add(hideButton);
7878

79+
this.interactButtonMap.clear();
7980
this.interactButtonMap.put(HotKeyType.N_QUICK_RESPONSE,inviteMeButton);
8081
this.interactButtonMap.put(HotKeyType.N_VISITE_HIDEOUT,visiteHideout);
8182
this.interactButtonMap.put(HotKeyType.N_TRADE_PLAYER,tradeButton);
@@ -106,7 +107,9 @@ protected void updateHotKeyPool() {
106107
.stream()
107108
.filter(it -> it.getType().equals(type))
108109
.findAny().orElse(null);
109-
this.hotKeysPool.put(hotKeyPair.getDescriptor(),button);
110+
if(!hotKeyPair.getDescriptor().getTitle().equals("...")) {
111+
this.hotKeysPool.put(hotKeyPair.getDescriptor(), button);
112+
}
110113
});
111114
}
112115

app-ui/src/main/java/com/mercury/platform/ui/components/panel/notification/controller/NotificationIncomingController.java

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
package com.mercury.platform.ui.components.panel.notification.controller;
22

33
import com.mercury.platform.shared.entity.message.ItemTradeNotificationDescriptor;
4+
import com.mercury.platform.shared.entity.message.MercuryError;
45
import com.mercury.platform.shared.entity.message.NotificationDescriptor;
56
import com.mercury.platform.shared.store.MercuryStoreCore;
67
import com.mercury.platform.ui.misc.MercuryStoreUI;
@@ -63,9 +64,13 @@ public void showITH() {
6364

6465
private void copyItemNameToClipboard(@NonNull String itemName){
6566
Timer timer = new Timer(30, action -> {
66-
StringSelection selection = new StringSelection(itemName);
67-
Clipboard clipboard = Toolkit.getDefaultToolkit().getSystemClipboard();
68-
clipboard.setContents(selection, null);
67+
try {
68+
StringSelection selection = new StringSelection(itemName);
69+
Clipboard clipboard = Toolkit.getDefaultToolkit().getSystemClipboard();
70+
clipboard.setContents(selection, null);
71+
}catch (IllegalStateException e){
72+
MercuryStoreCore.errorHandlerSubject.onNext(new MercuryError(e));
73+
}
6974
});
7075
timer.setRepeats(false);
7176
timer.start();

app-ui/src/main/java/com/mercury/platform/ui/components/panel/settings/page/HotKeyPanel.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -38,9 +38,9 @@ public void mousePressed(MouseEvent e) {
3838
MercuryStoreCore.hotKeySubject.subscribe(hotKey -> {
3939
if (hotKeyAllowed) {
4040
button.setBackground(AppThemeColor.BUTTON);
41-
if (hotKey.getVirtualKeyCode() == 27) {
41+
if (hotKey.getVirtualKeyCode() == 1) {
4242
this.descriptor.setTitle("...");
43-
this.descriptor.setVirtualKeyCode(0);
43+
this.descriptor.setVirtualKeyCode(-1);
4444
this.descriptor.setMenuPressed(false);
4545
this.descriptor.setShiftPressed(false);
4646
this.descriptor.setControlPressed(false);
@@ -51,7 +51,7 @@ public void mousePressed(MouseEvent e) {
5151
this.descriptor.setShiftPressed(hotKey.isShiftPressed());
5252
this.descriptor.setControlPressed(hotKey.isControlPressed());
5353
}
54-
button.setText(hotKey.getTitle());
54+
button.setText(this.descriptor.getTitle());
5555
hotKeyAllowed = false;
5656
button.addMouseListener(mouseAdapter);
5757
}

app-ui/src/main/java/com/mercury/platform/ui/frame/AbstractScalableComponentFrame.java

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,6 @@ public void setState(ScaleState state){
4545
this.scaleState = ScaleState.DEFAULT;
4646
this.setContentPane(mainContainer);
4747
this.setVisible(prevConstraints.visible);
48-
this.processEResize = prevConstraints.processEResize;
4948
this.setBackground(prevConstraints.bgColor);
5049
this.inScaleSettings = false;
5150
this.onScaleLock();
@@ -58,7 +57,6 @@ public void setState(ScaleState state){
5857
this.isVisible(),
5958
this.processEResize, this.getBackground()
6059
);
61-
this.processEResize = false;
6260
initDefaultView();
6361
this.setVisible(true);
6462
this.onScaleUnlock();

app-ui/src/main/java/com/mercury/platform/ui/frame/movable/ItemsGridFrame.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -57,7 +57,7 @@ public void subscribe() {
5757
this.pack();
5858
}
5959
});
60-
MercuryStoreUI.closeMessage.subscribe(message -> {
60+
MercuryStoreCore.removeNotificationSubject.subscribe(message -> {
6161
if(message instanceof ItemTradeNotificationDescriptor) {
6262
this.itemsGridPanel.remove((ItemTradeNotificationDescriptor) message);
6363
if (itemsGridPanel.getActiveTabsCount() == 0) {

0 commit comments

Comments
 (0)