Improvement requests
: K-Meleon Forum
Use this forum to talk about a feature you're missing. Use the bug tracker to report it if necessary.
Goto:
Forum List
•
Message List
•
Search
•
Log In
Your Name:
Subject:
Help information
BBcode help
Smileys help
[quote=siria] Oh man, as usual, after way too many hours of struggling and searching and experimenting and a couple more gray hairs, but finally got that stupid button to stay pressed!!! :P The syntax errors were in this line, 4x " and a . were missing: pluginmsg(toolbars,CheckButton,&Privacy Bar,macros(pref_ToggleObjects),(getpref... [color=red]Attention, there are 3 toggle states now, two of which look the same in button state! All blocked (button pressed) / Site allowed (button free) / All allowed (button free)[/color] If you don't want the second (only third-party objects blocked), simply remove the "3" from "1,2,3" in togglepref: So this is at last the CORRECT version: -------------------- macro: main2.kmm ---------------- [color=green]# ----- Accessibility/Privacy/Security $pref_Objects="[b]permissions.default.object[/b]"; pref_ToggleObjects{ macroinfo=_("Toggle object loading"); menuchecked=(getpref(INT,$pref_Objects)==2); togglepref(INT,$pref_Objects,[/color][color=red]1,2,3[/color][color=green]); &_pref_SyncButtons2; statusbar(sub("%s",getpref(INT,$pref_Objects)==2?$off:$on,_("Object loading %s"))); } # ----- PRIVATE # Menu Integration _pref_BuildMenu2{ setmenu(_Privacy_Settings,macro,"Block &Objects",pref_ToggleObjects); } $OnInit=$OnInit."_pref_BuildMenu2;"; # Toolbar Integration _pref_SyncButtons2{ pluginmsg(toolbars,"CheckButton","&Privacy Bar,macros(pref_ToggleObjects),".(getpref(INT,$pref_Objects)==2?1:0)); } $OnLoad=$OnLoad."_pref_SyncButtons2;"; $OnStartup=$OnStartup."_pref_SyncButtons2;"; # -------------------------------------------------------------[/color] The privbar-button was correct before, but just to have this complete: ---------------------- added to toolbar.cgf in skin folder -------------------- [color=green]Objects{ macros(pref_ToggleObjects)|&Privacy Block Objects [/color][color=red](3 Toggles: All blocked / Site allowed / All allowed)[/color][color=green] privhot.bmp[17] privcold.bmp[17] }[/color] ------------------------------------------------------------------- What that preference does, acc. to [b] http://kb.mozillazine.org/Hostperm.1 [/b] [color=blue][b] object Use the object selector to control the contents of <embed> and <object> tags, like plug-in content.[/b] This selector does not control the contents of <object> tags on 1.8 branch or earlier builds (i.e., Firefox 1.5.x, Camino 1.0.x, etc.). These builds will also render blocked content as a two-pixel vertical line with a height as specified by the HTML file. Recent trunk builds block <object> properly and render both <embed> and <object> content as invisible. A value of 1 maps to "allow", 2 maps to "deny" (or block), and 3 maps to "deny third-party".[/color] By the way, those 3 states also work for images, at least a quick test seems to confirm! :-)) Same trick as above, add a ",3" in the main.kmm (Not sure about cookies, theoretically they work too, even with another state "8" (session only), but on a test site it always says third-party cookies were accepted)[/quote]
[Please Enable JavaScript]
K-Meleon forum is powered by
Phorum
.
Home/News
Screenshots
Download
Documentation
Resources
Get Involved
Forum
Bugs
Development