Skip to content

Commit 9f45315

Browse files
author
peterdotjs
committed
Updating default shortcut keys.
1 parent 56588f9 commit 9f45315

File tree

10 files changed

+74
-36
lines changed

10 files changed

+74
-36
lines changed

css/style.less

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -736,7 +736,7 @@ button.disabled {
736736
z-index: 5;
737737
.modal-body {
738738
width: 550px;
739-
height: 400px;
739+
height: 440px;
740740

741741
.header-title-wrap {
742742
margin: 15px auto;
@@ -769,6 +769,10 @@ button.disabled {
769769
list-style: disc;
770770
margin-bottom: 10px;
771771
line-height: 18px;
772+
773+
&.no-decoration {
774+
list-style: none;
775+
}
772776
}
773777
}
774778

@@ -819,7 +823,7 @@ body.update {
819823
display: block;
820824
}
821825
.main-view {
822-
min-height: 500px;
826+
min-height: 530px;
823827
}
824828
}
825829

index.html

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -152,21 +152,33 @@
152152
<div class="header-title-wrap">
153153
<div class="icon-48"></div>
154154
<div class="header-title">
155-
Tab Resize 2.2.0 Updates
155+
Tab Resize 2.3.0 Updates
156156
</div>
157157
</div>
158158
<div class="update-list-header">What's New:</div>
159159
<ul class="update-list">
160160
<li class="update-entry">
161-
<strong>Scaled split screen layouts</strong> - you can now add split layouts for vertical and horizontal 7:3 and 6:4 ratio split screen in the custom view option by clicking the "+"icon in the extension popup.
161+
<strong>Default Keyboard Shortcut/Hotkeys Added:</strong>
162+
</li>
163+
<li class="update-entry no-decoration">
164+
<strong>CTRL + SHIFT + Z</strong>: Undo Last Resize
165+
</li>
166+
<li class="update-entry no-decoration">
167+
<strong>CTRL + SHIFT + 1</strong>: 1x1 Resize
168+
</li>
169+
<li class="update-entry no-decoration">
170+
<strong>CTRL + SHIFT + 2</strong>: 1x2 Resize
171+
</li>
172+
<li class="update-entry no-decoration">
173+
<strong>CTRL + SHIFT + 4</strong>: 2x2 Resize
162174
</li>
163175
<li class="update-entry">
164-
<strong>Keyboard Shortcut/Hotkeys enabled </strong> - You can now use tab resize with just keyboard shortcuts rather than opening up the extension from the icon. Add your own custom shotcut keys for various layout types by clicking here: <a class="keyboard-shortcuts" href="javascript:;" target="_blank">Keyboard shortcuts/hotkeys</a>
176+
You can <strong>use tab resize directly with keyboard shortcuts</strong> rather than opening up the extension from the icon. Add your own shortcuts by clicking here: <a class="keyboard-shortcuts" href="javascript:;" target="_blank">Keyboard shortcuts/hotkeys</a>
165177
</li>
166178
</ul>
167179

168180
<div class="additional-message bold">
169-
-- Past change log <a href="/options.html" target="_blank">details</a> --
181+
-- Past change log <a href="/options.html#change-log" target="_blank">details</a> --
170182
</div>
171183

172184
<div class="update-list-footer bold">

js/main_view.js

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,13 @@
7373

7474
var updateCount = Number(localStorage.getItem('updateBadge'));
7575

76-
if(!updateCount){
76+
var curVersion = localStorage.getItem('version') || '',
77+
isOldVersion = (curVersion < '2.3.1' && curVersion !== '');
78+
79+
localStorage.setItem('version','2.3.1');
80+
81+
if(!updateCount || isOldVersion){
82+
updateCount = 0;
7783
localStorage.setItem('updateBadge',0);
7884
chrome.browserAction.setBadgeText({text:'NEW'});
7985
chrome.browserAction.setBadgeBackgroundColor({color:[221, 129, 39, 255]});
@@ -88,9 +94,6 @@
8894
chrome.browserAction.setBadgeText({text:''});
8995
}
9096

91-
var curVersion = localStorage.getItem('version') || '',
92-
isOldVersion = (curVersion < '2.2.0' && curVersion !== '');
93-
9497
var $body = $('body');
9598

9699
//user has never seen update

js/options.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,7 @@
106106
$('body').removeClass('update');
107107
$('.main-view').removeClass('inactive');
108108
localStorage.setItem('update-seen',true);
109-
localStorage.setItem('version','2.2.0');
109+
localStorage.setItem('version','2.3.1');
110110
},
111111

112112
/**
@@ -155,4 +155,4 @@
155155

156156
window.resize.options = options;
157157

158-
})();
158+
})();

js/resize.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@
2828
custom_view: {},
2929
options: {},
3030
util: {},
31-
badgeLimit: 4,
31+
badgeLimit: 2,
3232
isMac: navigator.platform.toUpperCase().indexOf('MAC')!==-1
3333
};
3434

manifest.json

Lines changed: 16 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "Tab Resize - split screen layouts",
33
"short_name": "Tab Resize",
4-
"version": "2.2.9",
4+
"version": "2.3.0",
55
"manifest_version": 2,
66
"minimum_chrome_version": "30",
77
"description": "Split Screen made easy. Resize the CURRENT tab and tabs to the RIGHT into layouts on separate windows. w/ Multi Monitor Support.",
@@ -33,26 +33,35 @@
3333
}
3434
},
3535
"tab-resize-1-1": {
36-
"description": "Resize 1x1 layout"
36+
"description": "Resize 1x1 layout",
37+
"suggested_key": {
38+
"default": "Ctrl+Shift+1",
39+
"mac": "MacCtrl+Shift+1"
40+
}
3741
},
3842
"tab-resize-1-2": {
39-
"description": "Resize 1x2 layout"
43+
"description": "Resize 1x2 layout",
44+
"suggested_key": {
45+
"default": "Ctrl+Shift+2",
46+
"mac": "MacCtrl+Shift+2"
47+
}
4048
},
4149
"tab-resize-2-1": {
4250
"description": "Resize 2x1 layout"
4351
},
4452
"tab-resize-2-2": {
45-
"description": "Resize 2x2 layout"
53+
"description": "Resize 2x2 layout",
54+
"suggested_key": {
55+
"default": "Ctrl+Shift+4",
56+
"mac": "MacCtrl+Shift+4"
57+
}
4658
},
4759
"tab-resize-1-3": {
4860
"description": "Resize 1x3 layout"
4961
},
5062
"tab-resize-3-1": {
5163
"description": "Resize 3x1 layout"
5264
},
53-
"tab-resize-1-3": {
54-
"description": "Resize 1x3 layout"
55-
},
5665
"tab-resize-6-4-scale-horizontal": {
5766
"description": "Resize 6:4 layout"
5867
},

options.html

Lines changed: 14 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ <h1>Tab Resize - Options</h1>
88
<br/>
99
<iframe class="star-gazer" src="https://ghbtns.com/github-btn.html?user=peterdotjs&repo=tab-resize&type=star&count=true&size=large" frameborder="0" scrolling="0" width="160px" height="30px"></iframe>
1010

11-
<section>
11+
<section id="tips">
1212
<h2>Tips</h2>
1313
<h3>Tab Resize will always be FREE to use and an AD-FREE experience. I've gladly donated my time in creating and maintaining this project for you guys. In return I only ask that if you've found the extension useful and would like to show your support, <strong>consider donating a small amount to charity</strong>:</h3>
1414
<ul class="donate-wrap">
@@ -18,7 +18,7 @@ <h3>Tab Resize will always be FREE to use and an AD-FREE experience. I've gladly
1818
</ul>
1919
</section>
2020

21-
<section>
21+
<section id="issues">
2222
<h2>Issues/Questions/Feature Requests</h2>
2323
<h3>Github</h3>
2424
<ul>
@@ -34,13 +34,19 @@ <h3>Contact</h3>
3434
</ul>
3535
</section>
3636

37-
<section>
37+
<section id="change-log">
3838
<h2>Change Log</h2>
39-
<h3>2.2.7</h3>
39+
<h3>2.3.0</h3>
4040
<ul>
4141
<li class="update-entry">
42-
<strong>Default Undo Resize Shortcut</strong> - Added default shortcut key for "Undo Resize":
43-
"<strong>Ctrl + Shift + Z</strong>". The shortcut can still be changed through shortcut keys menu.
42+
<strong>Default Keyboard Shortcut/Hotkeys Added:</strong>
43+
<div><strong>CTRL + SHIFT + Z</strong>: Undo Last Resize</div>
44+
<div><strong>CTRL + SHIFT + 1</strong>: 1x1 Resize</div>
45+
<div><strong>CTRL + SHIFT + 2</strong>: 1x2 Resize</div>
46+
<div><strong>CTRL + SHIFT + 4</strong>: 2x2 Resize</div>
47+
</li>
48+
<li class="update-entry">
49+
The shortcuts can still be changed through shortcut keys menu.
4450
</li>
4551
</ul>
4652
<h3>2.2.0</h3>
@@ -49,7 +55,7 @@ <h3>2.2.0</h3>
4955
<strong>Scaled split screen layouts</strong> - you can now add split layouts for 7:3 and 6:4 ratio split screen in the custom view option by clicking the "+"icon in the extension popup.
5056
</li>
5157
<li class="update-entry">
52-
<strong>Keyboard Shortcut/Hotkeys enabled </strong> - You can now use tab resize with just keyboard shortcuts rather than opening up the extension from the icon. Add your own custom shotcut keys for various layout types by clicking: <a id="keyboard-shortcut-link" href="javascript:;" target="_blank">Keyboard Shortcuts/Hotkeys</a>
58+
<strong>Keyboard Shortcut/Hotkeys enabled </strong> - You can now use tab resize with just keyboard shortcuts rather than opening up the extension from the icon. Add your own custom shortcut keys for various layout types by clicking: <a id="keyboard-shortcut-link" href="javascript:;" target="_blank">Keyboard Shortcuts/Hotkeys</a>
5359
</li>
5460
</ul>
5561
<h3>2.1.1</h3>
@@ -75,7 +81,7 @@ <h3>2.0</h3>
7581
</ul>
7682
</section>
7783

78-
<section>
84+
<section id="analytics">
7985
<h2>Analytics</h2>
8086
<h3 class="update-entry"><strong>Google Analytics helps with providing a better user experience by understanding user behavior. NO personal information is used.</strong> Tab resize will ALWAYS remain an ad free extension. Only usage of different options and layouts are sent to help improve Tab Resize. You can choose to opt out of sending this anonymous analytical data by checking the box below.</h3>
8187
<p></p>

public/style.css

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

public/tabResize.js

Lines changed: 10 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@ if(!deferTracking) {
5454
custom_view: {},
5555
options: {},
5656
util: {},
57-
badgeLimit: 4,
57+
badgeLimit: 2,
5858
isMac: navigator.platform.toUpperCase().indexOf('MAC')!==-1
5959
};
6060

@@ -137,7 +137,13 @@ if(!deferTracking) {
137137

138138
var updateCount = Number(localStorage.getItem('updateBadge'));
139139

140-
if(!updateCount){
140+
var curVersion = localStorage.getItem('version') || '',
141+
isOldVersion = (curVersion < '2.3.1' && curVersion !== '');
142+
143+
localStorage.setItem('version','2.3.1');
144+
145+
if(!updateCount || isOldVersion){
146+
updateCount = 0;
141147
localStorage.setItem('updateBadge',0);
142148
chrome.browserAction.setBadgeText({text:'NEW'});
143149
chrome.browserAction.setBadgeBackgroundColor({color:[221, 129, 39, 255]});
@@ -152,9 +158,6 @@ if(!deferTracking) {
152158
chrome.browserAction.setBadgeText({text:''});
153159
}
154160

155-
var curVersion = localStorage.getItem('version') || '',
156-
isOldVersion = (curVersion < '2.2.0' && curVersion !== '');
157-
158161
var $body = $('body');
159162

160163
//user has never seen update
@@ -527,7 +530,7 @@ if(!deferTracking) {
527530
$('body').removeClass('update');
528531
$('.main-view').removeClass('inactive');
529532
localStorage.setItem('update-seen',true);
530-
localStorage.setItem('version','2.2.0');
533+
localStorage.setItem('version','2.3.1');
531534
},
532535

533536
/**
@@ -577,6 +580,7 @@ if(!deferTracking) {
577580
window.resize.options = options;
578581

579582
})();
583+
580584
/*
581585
* layout.js
582586
* adds/removes layout from popup

public/tabResize.min.js

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

0 commit comments

Comments
 (0)