MozillaZine

[Ext] userChrome.js

Announce and Discuss the Latest Theme and Extension Releases.
Diorser

User avatar
 
Posts: 960
Joined: June 22nd, 2005, 6:57 am

Post Posted June 2nd, 2006, 9:25 am

@zeniko
It is absolutely perfect ! Thanks !

Now looking to make slim download list (like slim extension list)
I don't find with userchrome.css ....

Any clue ?

Cato62

User avatar
 
Posts: 684
Joined: March 7th, 2005, 10:06 am
Location: Eugene, OR

Post Posted June 2nd, 2006, 9:30 am

Diorser wrote:Now looking to make slim download list (like slim extension list)
I don't find with userchrome.css ....

Any clue ?


Oooh, I'd like to see this too!
"It is difficult to fight against anger, for a man will buy revenge with his soul." ~ Heraclites, 500 B.C.

The Blood Series: BloodFire, BloodFire 3, BloodThunder, BloodSun, & BloodSong

dougeeebear

User avatar
 
Posts: 548
Joined: September 15th, 2005, 4:17 pm

Post Posted June 2nd, 2006, 10:37 am

Now to see if I can get the code to open Manage Bookmarks in a tab implemented into this snippet:

<a href="data:application/x-javascript;charset=utf-8;base64,PG92ZXJsYXkgaWQ9Im1hbmFnZUJvb2ttYXJrc0ZvbGRlcnMiDQogICB4bWxucz0iaHR0cDovL3d3dy5tb3ppbGxhLm9yZy9rZXltYXN0ZXIvZ2F0ZWtlZXBlci90aGVyZS5pcy5vbmx5Lnh1bCI%2BDQoNCjxzY3JpcHQgdHlwZT0iYXBwbGljYXRpb24veC1qYXZhc2NyaXB0Ij4NCnZhciBvbGRCb29rbWFya3NHZXRDb21tYW5kcyA9IHdpbmRvdy5Cb29rbWFya3NDb21tYW5kLmdldENvbW1hbmRzOw0KDQpCb29rbWFya3NDb21tYW5kLmdldENvbW1hbmRzID0gZnVuY3Rpb24gKG5vZGUsIHBhcmVudCwgZHMpDQp7DQogICAgdmFyIGNtZHMgPSBvbGRCb29rbWFya3NHZXRDb21tYW5kcyhub2RlLCBwYXJlbnQsIGRzKTsNCiAgICB2YXIgdHlwZSA9IEJvb2ttYXJrc1V0aWxzLnJlc29sdmVUeXBlKG5vZGUsIGRzKTsNCiAgICBpZih0eXBlID09ICJGb2xkZXIiKSBjbWRzLl9pbm5lci5zcGxpY2UoMSwgMCwgUkRGLkdldFJlc291cmNlKGdOQ19OU19DTUQgKyAnYm1fbWFuYWdlZm9sZGVyJykgKTsNCiAgICBpZih0eXBlID09ICJQZXJzb25hbFRvb2xiYXJGb2xkZXIiKSBjbWRzLl9pbm5lci5zcGxpY2UoMSwgMCwgUkRGLkdldFJlc291cmNlKGdOQ19OU19DTUQgKyAnYm1fbWFuYWdlZm9sZGVyJykgKTsNCiAgICByZXR1cm4gY21kczsNCn0NCjwvc2NyaXB0Pg0KDQo8IS0tIEZpcmVmb3ggQm9va21hcmsgQ29udGV4dCBNZW51IC0tPg0KICA8bWVudXBvcHVwIGlkPSJib29rbWFya3MtY29udGV4dC1tZW51Ij4NCiAgICA8bWVudWl0ZW0gY29tbWFuZD0iY21kX2JtX21hbmFnZWZvbGRlciIgbGFiZWw9Ik1hbmFnZSBGb2xkZXIiLz4NCiAgPC9tZW51cG9wdXA%2BDQoNCjwvb3ZlcmxheT4%3D">ManageBookmarksFolders.xul</a>

Diorser

User avatar
 
Posts: 960
Joined: June 22nd, 2005, 6:57 am

Post Posted June 2nd, 2006, 10:46 am

Sorry but what is different with the solution proposed by zeniko ?
Is it same result but another solution ?

dougeeebear

User avatar
 
Posts: 548
Joined: September 15th, 2005, 4:17 pm

Post Posted June 2nd, 2006, 10:53 am

The difference is this creates a bookmark context menu item that opens up a single bookmarks folder (or sub-menu) that is hilighted.
It opens in a window, and I want to see if I can get it to open it in a new tab instead.

Diorser

User avatar
 
Posts: 960
Joined: June 22nd, 2005, 6:57 am

Post Posted June 3rd, 2006, 5:09 am

  • <a href="data:application/x-javascript;charset=utf-8;base64,LyogIFRoaXMgc2NyaXB0IHdpbGwgYWRkICJIZWxsbywgV29ybGQhIiBtZW51aXRlbSBiZWZvcmUNCiAgICB0aGUgIk9wZW4gTGluayBpbiBOZXcgV2luZG93IiBtZW51aXRlbSBvbiBDb250ZXh0I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MEtHZ29BQUFBTlNVaEVVZ0FBQUJBQUFBQVFBUU1BQUFBbFBXMGlBQUFBRlhSRldIUkRjbVZoZEdsdmJpQlVhVzFsQUFmV0F4c1NLU1VONmlBZUFBQUFCM1JKVFVVSDFnTWJFaTA0MzRGcXN3QUFBQWx3U0ZsekFBQU9kQUFBRG5RQmF5U3oxZ0FBQUFaUVRGUkZBQUFBJTJGJTJGJTJGJTJGcGRtZjNRQUFBQ1ZKUkVGVWVOcGolMkJQJTJCZkFZS21uV0lvMndsQ2swNUJSYjcxTTN5WXolMkZCdFA0Z0JVd1lBaGNVYldjdWhlVDhBQUFBQVNVVk9SSzVDWUlJJTNEKSI7DQogIG5ld0J1dHRvbi5zdHlsZS5wYWRkaW5nID0gIjAiOw0KDQogIHZhciBob21lQnV0dG9uID0gZG9jdW1lbnQuZ2V0RWxlbWVudEJ5SWQoImhvbWUtYnV0dG9uIik7IC8vSG9tZSBidXR0b24NCiAgaG9tZUJ1dHRvbi5wYXJlbnROb2RlLmluc2VydEJlZm9yZShuZXdCdXR0b24sIGhvbWVCdXR0b24ubmV4dFNpYmxpbmcpOyAvL2FkZHMgdGhlIG5ldyBidXR0b24gb24gdGhlIHJpZ2h0IG9mIEhvbWUgYnV0dG9uDQoNCn0pKCk7DQoNCg%3D%3D">Adds a toolbarbutton</a>
These codes have absolutely have no effect for me with Fx 1.5.0.4; could somebody confirm ?

Thanks.

dougeeebear

User avatar
 
Posts: 548
Joined: September 15th, 2005, 4:17 pm

Post Posted June 3rd, 2006, 5:34 am

Diorser,
#1, check js console for error (doesn't work even after error is corrected).
#2, WFM.

KidReefer

User avatar
 
Posts: 141
Joined: May 7th, 2006, 6:10 am
Location: Earth...mainly

Post Posted June 3rd, 2006, 5:47 am

Error: [Exception... "Component is not available" nsresult: "0x80040111 (NS_ERROR_NOT_AVAILABLE)" location: "JS frame :: <unknown filename> :: setup :: line 122" data: no]
Nevermind got it
Last edited by KidReefer on June 3rd, 2006, 7:58 am, edited 1 time in total.

Diorser

User avatar
 
Posts: 960
Joined: June 22nd, 2005, 6:57 am

Post Posted June 3rd, 2006, 6:16 am

dougeeebear wrote:#1, check js console for error (doesn't work even after error is corrected).

Absolutely no JS error, but does not work at all (Fx 1.5.0.4).

Even with NoScript disabled !

dougeeebear

User avatar
 
Posts: 548
Joined: September 15th, 2005, 4:17 pm

Post Posted June 3rd, 2006, 6:40 am

Diorser wrote:Absolutely no JS error


<code>Error: missing ) in parenthetical
Source file: file:///C:/Program%20Files/Mozilla%20Firefox/Profile/chrome/test.uc.js
Line: 12, Column: 3
Source code:
}();</code>

JNewbry

User avatar
 
Posts: 321
Joined: April 9th, 2005, 3:56 am
Location: Dallas,TX

Post Posted June 3rd, 2006, 6:41 am

Diorser:
Hmmm... works for me in 1.5.0.4. (after correcting the code)
I get the "Hello World" menu item at the top of the context, click it and get a popup saying "Hello World"

While I'm here.... Has anyone played with Thunderbird yet with this extension?
I haven't seen any code posted yet for TB....
<a href="http://webdesigns.ms11.net/chromeditp.html" target="_blank">ChromEdit Plus</a> | <a href="http://webdesigns.ms11.net/winstripethemes.html" target="_blank">Firefox Themes</a>

old zeniko
 
Posts: 0
Joined: December 31st, 1969, 5:00 pm

Post Posted June 3rd, 2006, 6:53 am

To give you an input for Thunderbird, I currently apply these <a href="data:text/javascript,%2F*%20%3A%3A%3A%3A%3A%3A%3A%3A%20Search%20Toolbar%20Item%20%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%20*%2F%0A%0A(function()%20%7B%0A%09var%20throbber%20%3D%20document.getElementById(%22throbber-box%22)%3B%0A%09var%20searchBox%20%3D%20document.getElementById(%22searchBox%22)%3B%0A%09if%20(!throbber%20%7C%7C%20!searchBox)%0A%09%7B%0A%09%09return%3B%0A%09%7D%0A%09var%20toolbaritem%20%3D%20document.createElement(%22toolbaritem%22)%3B%0A%09throbber.parentNode.insertBefore(toolbaritem%2C%20throbber)%3B%0A%09toolbaritem.appendChild(searchBox)%3B%0A%09toolbaritem.flex%20%3D%203%3B%0A%09searchBox.flex%20%3D%201%3B%0A%7D)()%3B%0A%0A%0A%2F*%20%3A%3A%3A%3A%3A%3A%3A%3A%20Disabled%20Throbber%20%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%20*%2F%0A%0A(function()%20%7B%0A%09var%20throbber%20%3D%20document.getElementById(%22navigator-throbber%22)%3B%0A%09if%20(!throbber)%0A%09%7B%0A%09%09return%3B%0A%09%7D%0A%09throbber.setAttribute(%22disabled%22%2C%20%22true%22)%3B%0A%09throbber.removeAttribute(%22tooltiptext%22)%3B%0A%7D)()%3B%0A%0A%0A%2F*%20%3A%3A%3A%3A%3A%3A%3A%3A%20Select%20Inbox%20on%20Startup%20%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%20*%2F%0A%0Aif%20(!window.arguments%20%7C%7C%20!window.arguments%5B0%5D)%0A%7B%0A%09window.arguments%20%3D%20%5B%22mailbox%3A%2F%2Fnobody%40Local%2520Folders%2FInbox%22%2C%20-1%5D%3B%0A%7D%0A%0A%0A%2F*%20%3A%3A%3A%3A%3A%3A%3A%3A%20No%20New%20Window%20on%20Double%20Click%20%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%3A%20*%2F%0A%0Aeval(%22FolderPaneDoubleClick%20%3D%20%22%20%2B%20FolderPaneDoubleClick.toString().replace(%2Felse%20%7B%5B%5E%7D%5D%2B%7D%2F%2C%20%22%22))%3B%0A">four simple snippets</a> (for the first snippet there's some corresponding <a href="data:text/css,%23mail-toolbar-menubar%20%7B%0A%09border-bottom%3A%200px%20!important%3B%0A%7D%0A%0A%23folderpane_splitter%20%7B%0A%09border-top%3A%200px%20!important%3B%0A%7D%0A%23folderpane_splitter%5Bflatmenu%3D%22true%22%5D%20%7B%0A%09border-top%3A%201px%20solid%20ThreeDShadow%20!important%3B%0A%09border-bottom%3A%201px%20solid%20ThreeDShadow%20!important%3B%0A%7D%0A%0A%23searchBox%20%7B%0A%09border-top%3A%200px%20!important%3B%0A%09height%3A%20auto%20!important%3B%0A%7D%0A%0A%23folderPaneHeader%20%7B%0A%09display%3A%20none%20!important%3B%0A%7D%0A">userChrome.css code</a>).

AnonEmoose
 
Posts: 2031
Joined: February 6th, 2004, 11:59 am

Post Posted June 3rd, 2006, 6:55 am

both scripts work for me (After the missing parenthesis is added).

Make sure you have the home button on your toolbar ;-) :-)

JNewbry

User avatar
 
Posts: 321
Joined: April 9th, 2005, 3:56 am
Location: Dallas,TX

Post Posted June 3rd, 2006, 7:06 am

zeniko... Thank you sir!
<a href="http://webdesigns.ms11.net/chromeditp.html" target="_blank">ChromEdit Plus</a> | <a href="http://webdesigns.ms11.net/winstripethemes.html" target="_blank">Firefox Themes</a>

Diorser

User avatar
 
Posts: 960
Joined: June 22nd, 2005, 6:57 am

Post Posted June 3rd, 2006, 7:20 am

dougeeebear wrote:<code>Error: missing ) in parenthetical
Source file: file:///C:/Program%20Files/Mozilla%20Firefox/Profile/chrome/test.uc.js
Line: 12, Column: 3
Source code:
}();</code>

:?:

.../...

Afters some trials (........), got it => })(); at the end of the script.
Last edited by Diorser on June 3rd, 2006, 7:28 am, edited 1 time in total.

Return to Extension/Theme Releases


Who is online

Users browsing this forum: No registered users and 0 guests