summaryrefslogtreecommitdiff
path: root/js/userdesign.go.js
diff options
context:
space:
mode:
authorZach Copley <zach@controlyourself.ca>2009-09-08 16:02:57 -0700
committerZach Copley <zach@controlyourself.ca>2009-09-08 16:02:57 -0700
commit9d87313eaebe8240393ac300a435f3b1332c8849 (patch)
tree6b7e7d69c63fc6801ad95477be9c11ccb7cd0a1a /js/userdesign.go.js
parent5efe588174c71979fc1970353c9a556ea441f138 (diff)
parentbeae3db41375879e725af053edf8041bbd76ac8c (diff)
Merge branch '0.9.x' into pluginize-twitter-bridge
Conflicts: plugins/TwitterBridge/twitterauthorization.php
Diffstat (limited to 'js/userdesign.go.js')
-rw-r--r--js/userdesign.go.js11
1 files changed, 6 insertions, 5 deletions
diff --git a/js/userdesign.go.js b/js/userdesign.go.js
index c53569bea..eb4dece09 100644
--- a/js/userdesign.go.js
+++ b/js/userdesign.go.js
@@ -1,10 +1,10 @@
/** Init for Farbtastic library and page setup
*
- * @package Laconica
- * @author Sarven Capadisli <csarven@controlyourself.ca>
- * @copyright 2009 Control Yourself, Inc.
+ * @package StatusNet
+ * @author Sarven Capadisli <csarven@status.net>
+ * @copyright 2009 StatusNet, Inc.
* @license http://www.fsf.org/licensing/licenses/agpl-3.0.html GNU Affero General Public License version 3.0
- * @link http://laconi.ca/
+ * @link http://status.net/
*/
$(document).ready(function() {
function InitColors(i, E) {
@@ -27,11 +27,12 @@ $(document).ready(function() {
}
}
- /* rgb2hex written by R0bb13 <robertorebollo@gmail.com> */
function rgb2hex(rgb) {
+ if (rgb.slice(0,1) == '#') { return rgb; }
rgb = rgb.match(/^rgb\((\d+),\s*(\d+),\s*(\d+)\)$/);
return '#' + dec2hex(rgb[1]) + dec2hex(rgb[2]) + dec2hex(rgb[3]);
}
+ /* dec2hex written by R0bb13 <robertorebollo@gmail.com> */
function dec2hex(x) {
hexDigits = new Array('0','1','2','3','4','5','6','7','8','9','A','B','C','D','E','F');
return isNaN(x) ? '00' : hexDigits[(x - x % 16) / 16] + hexDigits[x % 16];