Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
40 changes: 1 addition & 39 deletions chrome/background.html
Original file line number Diff line number Diff line change
@@ -1,45 +1,7 @@
<!doctype html>
<html>
<head>
<meta http-equiv="Content-Type" content="text/html;charset=UTF-8">
<script>
if (localStorage.openin === undefined)
localStorage.openin = 'window';
if (localStorage.deleteconfirm === undefined)
localStorage.deleteconfirm = 'yes';
if (localStorage.encryption === undefined)
localStorage.encryption = 'no';

localStorage.tempWindowNames = "{}";

chrome.extension.onRequest.addListener(
function(request, sender, sendResponse) {
if (localStorage.openin === 'window') {
chrome.windows.create({}, function (window) {
chrome.tabs.getAllInWindow(window.id, function (tabs) {
chrome.tabs.remove(tabs[0].id);
});
request.tabs.forEach(function (tab) {
curTab = {
windowId: window.id,
url: tab.url,
selected: false
};
if (localStorage.supportPinned == 1 && tab.pinned) {
curTab.pinned = true;
}
chrome.tabs.create(curTab);
});
});
} else if (localStorage.openin === 'tab') {
request.tabs.forEach(function (tab) {
chrome.tabs.create({
url: tab.url
});
});
}
});
</script>

</head>
<body>
</body>
Expand Down
7 changes: 7 additions & 0 deletions chrome/css/jquery-ui.min.css

Large diffs are not rendered by default.

62 changes: 62 additions & 0 deletions chrome/css/options.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,62 @@
body {
margin: 10px;
min-width: 47em;
}

a {
color: blue;
font-size: 103%;
}

#header {
margin-bottom: 1.05em;
overflow: hidden;
padding-bottom: 1.5em;
padding-left: 0;
padding-top: 1.5em;
position: relative;
}

#header h1 {
background: url("../images/icon65.png") 0px 20px no-repeat;
display: inline;
margin: 0;
padding-bottom: 43px;
padding-left: 75px;
padding-top: 40px;
}

h1 {
font-size: 156%;
font-weight: bold;
padding: 0;
margin: 0;
}

.section-header {
background: #ebeff9;
border-top: 1px solid #b5c7de;
font-size: 99%;
padding-bottom: 2px;
padding-left: 5px;
padding-top: 3px;
width: 100%;
margin-top: 10px;
}

.box {
border-bottom: 1px solid #ccc;
padding: 10px;
}

.optioninput {
float: right;
width: 30%
text-align: right;
font-weight: bold;
}

.optiontext {
float: left;
width: 70%;
}
124 changes: 124 additions & 0 deletions chrome/css/popup.css
Original file line number Diff line number Diff line change
@@ -0,0 +1,124 @@
* {
margin: 0;
padding: 0;
}
.tabplaceholder {
float: left;
width: 20px;
background-color: #ccc;
border-radius: 2px;
}
#trash .tabplaceholder {
opacity: 0.6;
}
html {
height: 152px;
}
body {
height: 152px;
font-size: 0.9em;
font-family: sans-serif;
}
.window {
border: 1px solid #ccc;
border-radius: 5px;
margin: 5px;
padding: 5px;
background-color: white;
}
.window legend {
padding: 0 2px;
background-color: white;
}
.tabs img {
margin: 2px;
width: 16px;
height: 16px;
}
.tabs {
padding: 0;
height: 20px;
}
#current {
border-bottom: 1px solid black;
}
.info {
border: 1px solid #ccc;
border-radius: 5px;
margin: 10px 5px;
text-align: center;
padding: 5px;
float:left;
width: 232px;
height: 24px;
font-size: 0.7em;
}

.infobox {
border: 1px solid #ccc;
border-radius: 5px;
margin: 10px 5px;
text-align: center;
padding-top: 12px;
float:left;
width: 287px;
height: 24px;
font-size: 0.7em;
}

#trash {
border: 1px solid #ccc;
border-radius: 5px;
margin: 10px 5px;
padding: 8px;
float: left;
height: 18px;
width: 18px;
background: url(../images/bin_empty.png) no-repeat 50% 50%;
}
.tips {
margin: 0px;
padding: 0px;
}
.right {
position: absolute;
right: 15px;
margin-top: -22px;
background-color: white;
padding: 2px;
}
.right img {
padding: 1px;
}
.decryptpass {
width: 150px !important;
}

#tips span {
width: 100%;
}
#tips {
margin-bottom: 3px;
}
.confirm {
display: block;
margin-top: -3px;
color: white;
background-color: #e9594d;
border-radius: 5px;
padding: 2px;
}
.confirm img {
vertical-align: middle;
}

#scrollbar { width: 310px; clear: both; }
#scrollbar .viewport { width: 300px; overflow: hidden; position: relative; height: 0; }
#scrollbar .overview { width: 300px; list-style: none; position: absolute; left: 0; top: 0; }
#scrollbar .thumb .end,
#scrollbar .thumb { background: transparent url(../images/bg-scrollbar.png) no-repeat; }
#scrollbar .scrollbar { position: relative; background-position: 0 0; float: right; width: 10px; }
#scrollbar .track { height: 100%; width:6px; position: relative; padding: 0 1px; }
#scrollbar .thumb { background-position: 100% 100%; height: 20px; width: 8px; cursor: pointer; overflow: hidden; position: absolute; top: 0; }
#scrollbar .thumb .end { background-position: 100% 0; height: 5px; width: 8px; }
#scrollbar .disable { display: none; }
Binary file added chrome/images/disk_overwrite.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
36 changes: 36 additions & 0 deletions chrome/lib/background.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
if (localStorage.openin === undefined)
localStorage.openin = 'window';
if (localStorage.deleteconfirm === undefined)
localStorage.deleteconfirm = 'yes';
if (localStorage.encryption === undefined)
localStorage.encryption = 'no';

localStorage.tempWindowNames = "{}";

chrome.extension.onRequest.addListener(
function(request, sender, sendResponse) {
if (localStorage.openin === 'window') {
chrome.windows.create({}, function (window) {
chrome.tabs.getAllInWindow(window.id, function (tabs) {
chrome.tabs.remove(tabs[0].id);
});
request.tabs.forEach(function (tab) {
curTab = {
windowId: window.id,
url: tab.url,
selected: false
};
if (localStorage.supportPinned == 1 && tab.pinned) {
curTab.pinned = true;
}
chrome.tabs.create(curTab);
});
});
} else if (localStorage.openin === 'tab') {
request.tabs.forEach(function (tab) {
chrome.tabs.create({
url: tab.url
});
});
}
});
Loading