author | Clipperz <info@clipperz.com> | 2013-01-31 13:42:04 (UTC) |
---|---|---|
committer | Clipperz <info@clipperz.com> | 2013-01-31 13:42:04 (UTC) |
commit | 07d0357beef5d9328a2dd8d07ad7b39c87ac55e4 (patch) (unidiff) | |
tree | f7a4aed8848302db153c2a211f8e58b944eb4c5b /frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js | |
parent | 767a3dcf48b6ac911c088af5dd7738a728eb6b99 (diff) | |
download | clipperz-07d0357beef5d9328a2dd8d07ad7b39c87ac55e4.zip clipperz-07d0357beef5d9328a2dd8d07ad7b39c87ac55e4.tar.gz clipperz-07d0357beef5d9328a2dd8d07ad7b39c87ac55e4.tar.bz2 |
Updated Copyright claims
- updated reference dates;
- removed reference to Community Edition;
- normalized logging using Clipperz.log[Warn|Error|Debug]
Diffstat (limited to 'frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js') (more/less context) (ignore whitespace changes)
-rw-r--r-- | frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js b/frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js index cd7ed90..21dfcc0 100644 --- a/frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js +++ b/frontend/gamma/js/Clipperz/PM/UI/Canvas/Tips/close.js | |||
@@ -1,118 +1,116 @@ | |||
1 | /* | 1 | /* |
2 | 2 | ||
3 | Copyright 2008-2011 Clipperz Srl | 3 | Copyright 2008-2013 Clipperz Srl |
4 | 4 | ||
5 | This file is part of Clipperz Community Edition. | 5 | This file is part of Clipperz, the online password manager. |
6 | Clipperz Community Edition is an online password manager. | ||
7 | For further information about its features and functionalities please | 6 | For further information about its features and functionalities please |
8 | refer to http://www.clipperz.com. | 7 | refer to http://www.clipperz.com. |
9 | 8 | ||
10 | * Clipperz Community Edition is free software: you can redistribute | 9 | * Clipperz is free software: you can redistribute it and/or modify it |
11 | it and/or modify it under the terms of the GNU Affero General Public | 10 | under the terms of the GNU Affero General Public License as published |
12 | License as published by the Free Software Foundation, either version | 11 | by the Free Software Foundation, either version 3 of the License, or |
13 | 3 of the License, or (at your option) any later version. | 12 | (at your option) any later version. |
14 | 13 | ||
15 | * Clipperz Community Edition is distributed in the hope that it will | 14 | * Clipperz is distributed in the hope that it will be useful, but |
16 | be useful, but WITHOUT ANY WARRANTY; without even the implied | 15 | WITHOUT ANY WARRANTY; without even the implied warranty of |
17 | warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. | 16 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. |
18 | See the GNU Affero General Public License for more details. | 17 | See the GNU Affero General Public License for more details. |
19 | 18 | ||
20 | * You should have received a copy of the GNU Affero General Public | 19 | * You should have received a copy of the GNU Affero General Public |
21 | License along with Clipperz Community Edition. If not, see | 20 | License along with Clipperz. If not, see http://www.gnu.org/licenses/. |
22 | <http://www.gnu.org/licenses/>. | ||
23 | 21 | ||
24 | */ | 22 | */ |
25 | 23 | ||
26 | // | 24 | // |
27 | //close.js | 25 | //close.js |
28 | //close | 26 | //close |
29 | // | 27 | // |
30 | //Created by Giulio Cesare Solaroli on 3/14/10 | 28 | //Created by Giulio Cesare Solaroli on 3/14/10 |
31 | //Copyright 2010 Clipperz | 29 | //Copyright 2010 Clipperz |
32 | //This code was generated by Opacity. You may use or modify it in any way. | 30 | //This code was generated by Opacity. You may use or modify it in any way. |
33 | // | 31 | // |
34 | 32 | ||
35 | var kClipperz_PM_UI_Canvas_Tips_closeWidth = 310.0; | 33 | var kClipperz_PM_UI_Canvas_Tips_closeWidth = 310.0; |
36 | var kClipperz_PM_UI_Canvas_Tips_closeHeight = 6.0; | 34 | var kClipperz_PM_UI_Canvas_Tips_closeHeight = 6.0; |
37 | 35 | ||
38 | function Clipperz_PM_UI_Canvas_Tips_close(canvas, aColor, aBackgroundColor) | 36 | function Clipperz_PM_UI_Canvas_Tips_close(canvas, aColor, aBackgroundColor) |
39 | { | 37 | { |
40 | var context = canvas.getContext("2d"); | 38 | var context = canvas.getContext("2d"); |
41 | var alignStroke; | 39 | var alignStroke; |
42 | var resolution; | 40 | var resolution; |
43 | var path; | 41 | var path; |
44 | var pointX; | 42 | var pointX; |
45 | var pointY; | 43 | var pointY; |
46 | if (window.devicePixelRatio) | 44 | if (window.devicePixelRatio) |
47 | resolution = window.devicePixelRatio; | 45 | resolution = window.devicePixelRatio; |
48 | else | 46 | else |
49 | resolution = 1.0; | 47 | resolution = 1.0; |
50 | resolution *= 0.5 * (canvas.width / kClipperz_PM_UI_Canvas_Tips_closeWidth + canvas.height / kClipperz_PM_UI_Canvas_Tips_closeHeight); | 48 | resolution *= 0.5 * (canvas.width / kClipperz_PM_UI_Canvas_Tips_closeWidth + canvas.height / kClipperz_PM_UI_Canvas_Tips_closeHeight); |
51 | 49 | ||
52 | context.save(); | 50 | context.save(); |
53 | context.scale(canvas.width / kClipperz_PM_UI_Canvas_Tips_closeWidth, canvas.height / kClipperz_PM_UI_Canvas_Tips_closeHeight); | 51 | context.scale(canvas.width / kClipperz_PM_UI_Canvas_Tips_closeWidth, canvas.height / kClipperz_PM_UI_Canvas_Tips_closeHeight); |
54 | context.clearRect(0.0, 0.0, kClipperz_PM_UI_Canvas_Tips_closeWidth, kClipperz_PM_UI_Canvas_Tips_closeHeight); | 52 | context.clearRect(0.0, 0.0, kClipperz_PM_UI_Canvas_Tips_closeWidth, kClipperz_PM_UI_Canvas_Tips_closeHeight); |
55 | 53 | ||
56 | // background | 54 | // background |
57 | 55 | ||
58 | alignStroke = 0.0; | 56 | alignStroke = 0.0; |
59 | context.beginPath(); | 57 | context.beginPath(); |
60 | pointX = 310.0; | 58 | pointX = 310.0; |
61 | pointY = 6.0; | 59 | pointY = 6.0; |
62 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 60 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
63 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 61 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
64 | context.moveTo(pointX, pointY); | 62 | context.moveTo(pointX, pointY); |
65 | pointX = 310.0; | 63 | pointX = 310.0; |
66 | pointY = 0.0; | 64 | pointY = 0.0; |
67 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 65 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
68 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 66 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
69 | context.lineTo(pointX, pointY); | 67 | context.lineTo(pointX, pointY); |
70 | pointX = 0.0; | 68 | pointX = 0.0; |
71 | pointY = 0.0; | 69 | pointY = 0.0; |
72 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 70 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
73 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 71 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
74 | context.lineTo(pointX, pointY); | 72 | context.lineTo(pointX, pointY); |
75 | pointX = 0.0; | 73 | pointX = 0.0; |
76 | pointY = 6.0; | 74 | pointY = 6.0; |
77 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 75 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
78 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 76 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
79 | context.lineTo(pointX, pointY); | 77 | context.lineTo(pointX, pointY); |
80 | pointX = 310.0; | 78 | pointX = 310.0; |
81 | pointY = 6.0; | 79 | pointY = 6.0; |
82 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 80 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
83 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 81 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
84 | context.lineTo(pointX, pointY); | 82 | context.lineTo(pointX, pointY); |
85 | context.closePath(); | 83 | context.closePath(); |
86 | context.fillStyle = aBackgroundColor; | 84 | context.fillStyle = aBackgroundColor; |
87 | context.fill(); | 85 | context.fill(); |
88 | 86 | ||
89 | // grid | 87 | // grid |
90 | 88 | ||
91 | // background | 89 | // background |
92 | 90 | ||
93 | alignStroke = 0.0; | 91 | alignStroke = 0.0; |
94 | context.beginPath(); | 92 | context.beginPath(); |
95 | pointX = 310.0; | 93 | pointX = 310.0; |
96 | pointY = 6.0; | 94 | pointY = 6.0; |
97 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 95 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
98 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 96 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
99 | context.moveTo(pointX, pointY); | 97 | context.moveTo(pointX, pointY); |
100 | pointX = 310.0; | 98 | pointX = 310.0; |
101 | pointY = 0.0; | 99 | pointY = 0.0; |
102 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 100 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
103 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 101 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
104 | context.lineTo(pointX, pointY); | 102 | context.lineTo(pointX, pointY); |
105 | pointX = 0.0; | 103 | pointX = 0.0; |
106 | pointY = 0.0; | 104 | pointY = 0.0; |
107 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 105 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
108 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 106 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
109 | context.lineTo(pointX, pointY); | 107 | context.lineTo(pointX, pointY); |
110 | pointX = 0.0; | 108 | pointX = 0.0; |
111 | pointY = 6.0; | 109 | pointY = 6.0; |
112 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 110 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
113 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 111 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |
114 | context.lineTo(pointX, pointY); | 112 | context.lineTo(pointX, pointY); |
115 | pointX = 310.0; | 113 | pointX = 310.0; |
116 | pointY = 6.0; | 114 | pointY = 6.0; |
117 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; | 115 | pointX = (Math.round(resolution * pointX + alignStroke) - alignStroke) / resolution; |
118 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; | 116 | pointY = (Math.round(resolution * pointY + alignStroke) - alignStroke) / resolution; |