Extensions :  K-Meleon Web Browser Forum
All about K-Meleon extensions. 
Pages: 12Next
Current Page: 1 of 2
ublock for kmeleon 75
Posted by: soccerfan
Date: January 30, 2015 09:08PM

The ad blocker ublock looks very promising,
A firefox .xpi extension is available
(requires firefox v 31 or higher):

https://github.com/gorhill/uBlock/releases

Any help porting it to kmeleon75 would be appreciated. Thanks.

soccerfan



Edited 1 time(s). Last edit at 01/30/2015 09:10PM by soccerfan.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: guenter
Date: February 02, 2015 04:11PM

You mean activate it?

Use xpinstallext.kmm and install the attached xpi to suppress compatibility checking even further. And then test what it does. I think some may work.

Use URL chrome://ublock/content/dashboard.html to get options full size.
Or create a kmm using the URL.

Tab 3rd party filter lists does constantly load. Console shows no error.:s

I did not test further. It is Your pet after all. tongue sticking out smiley



Edited 1 time(s). Last edit at 02/02/2015 04:13PM by guenter.

Attachments: check-compatibility@dactyl.googlecode.com.xpi (4.2 KB)  
Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Dorian
Date: February 02, 2015 05:58PM

This extension need a feature not available in current version. I'll add it in next update but don't know how it will work.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: February 02, 2015 06:22PM

Thanks Dorian. I'll wait for the update.

@guenter: I'll give your instructions a go
(except writing a kmm which I cannot do!).

soccerfan

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: guenter
Date: February 02, 2015 10:32PM

Ok - create a link in bookmarks.html then. smiling smiley I use hotlist for this.

p.s. Actually You'd take an existing macro, give it a new unique name like ublock.kmm and alter the code a little. I must admit I never did anything more.

Making up new macros is only for macro coders like siria and JamesD. grinning smiley

I choose mtypes.kmm. But console2.kmm is also good for this.

Change the chrome line. Which I did for You.

Then You'd search & replace with an editor all instances of mtypes with ublock. Which I did not.

Then change what appears in the menu. That is the string "MIME T&ypes".
And maybe change the macro info. What extension it is...

"Preferences" is where the menu item is. Change it to "KMAbout" and it is in "Help". That is my favourite for my helper.kmm.

You can look up places in other macros.

That is all the art. No coding needed. smiling smiley


# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)

# ---------- mtypes Extension (MIME Type Editor) -------------------------------------------------------------------
#
# Dependencies : main.kmm (OpenURL)
# Resources : -
# Preferences : -
#
# ------------------------------------------------------------------------------------------------------------------

mtypes{
macroinfo=_("Change file type settings");
$OpenURL="chrome://ublock/content/dashboard.html"; &OpenURL_InNewWindow;
}

# ----- PRIVATE

_mtypes_BuildMenu{
# edit menu
setmenu(Preferences,macro,"MIME T&ypes...",mtypes);
}
$OnInit=$OnInit."_mtypes_BuildMenu;";

# ------------------------------------------------------------------------------------------------------------------
$macroModules=$macroModules."mtypes;";



Edited 1 time(s). Last edit at 02/02/2015 10:51PM by guenter.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: George_Hall
Date: February 03, 2015 04:02AM

Quote
guenter
Ok - create a link in bookmarks.html then. smiling smiley I use hotlist for this.

p.s. Actually You'd take an existing macro, give it a new unique name like ublock.kmm and alter the code a little. I must admit I never did anything more.

Making up new macros is only for macro coders like siria and JamesD. grinning smiley

I choose mtypes.kmm. But console2.kmm is also good for this.

Change the chrome line. Which I did for You.

Then You'd search & replace with an editor all instances of mtypes with ublock. Which I did not.

Then change what appears in the menu. That is the string "MIME T&ypes".
And maybe change the macro info. What extension it is...

"Preferences" is where the menu item is. Change it to "KMAbout" and it is in "Help". That is my favourite for my helper.kmm.

You can look up places in other macros.

That is all the art. No coding needed. smiling smiley


# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)


# ---------- mtypes Extension (MIME Type Editor) -------------------------------------------------------------------
#
# Dependencies : main.kmm (OpenURL)
# Resources : -
# Preferences : -
#
# ------------------------------------------------------------------------------------------------------------------

ublock{
macroinfo=_("Change file type settings");
$OpenURL="chrome://ublock/content/dashboard.html"; &OpenURL_InNewWindow;
}

# ----- PRIVATE

_ublock_BuildMenu{
# edit menu
setmenu(Preferences,macro,"MIME T&ypes...",mtypes);
}
$OnInit=$OnInit."_mtypes_BuildMenu;";

# ------------------------------------------------------------------------------------------------------------------
$macroModules=$macroModules."mtypes;";

You made one mistake the internal mtypes needs to replaces with somethng like ublock or your macro interfere with the mtypes macro.

The ublock macro should be soemthing like the similar to the one below.

# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)

# ---------- UBlock Add Block Extension
-------------------------------------------------------------------
#
# Dependencies : main.kmm (OpenURL)
# Resources : -
# Preferences : -
#
# ------------------------------------------------------------------------------------------------------------------

ublock{
macroinfo=_("uBlock Add Blocker");
$OpenURL="chrome://ublock/content/dashboard.html"; &OpenURL_InNewWindow;
}

# ----- PRIVATE

_ublock_BuildMenu{
# edit menu
setmenu(Preferences,macro,"uBlock Add Blocker...",ublock);
}
$OnInit=$OnInit."_ublock_BuildMenu;";

# ------------------------------------------------------------------------------------------------------------------
$macroModules=$macroModules."ublock;"



Edited 2 time(s). Last edit at 02/03/2015 04:10AM by George_Hall.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: guenter
Date: February 03, 2015 08:29AM

Quote
George_Hall
Quote
guenter
Ok - create a link in bookmarks.html then. smiling smiley I use hotlist for this.

p.s. Actually You'd take an existing macro, give it a new unique name like ublock.kmm and alter the code a little. I must admit I never did anything more.

Making up new macros is only for macro coders like siria and JamesD. grinning smiley

I choose mtypes.kmm. But console2.kmm is also good for this.

Change the chrome line. Which I did for You.

Then You'd search & replace with an editor all instances of mtypes with ublock. Which I did not.

Then change what appears in the menu. That is the string "MIME T&ypes".
And maybe change the macro info. What extension it is...

"Preferences" is where the menu item is. Change it to "KMAbout" and it is in "Help". That is my favourite for my helper.kmm.

You can look up places in other macros.

That is all the art. No coding needed. smiling smiley


# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)


# ---------- mtypes Extension (MIME Type Editor) -------------------------------------------------------------------
#
# Dependencies : main.kmm (OpenURL)
# Resources : -
# Preferences : -
#
# ------------------------------------------------------------------------------------------------------------------

ublock{
macroinfo=_("Change file type settings");
$OpenURL="chrome://ublock/content/dashboard.html"; &OpenURL_InNewWindow;
}

# ----- PRIVATE

_ublock_BuildMenu{
# edit menu
setmenu(Preferences,macro,"MIME T&ypes...",mtypes);
}
$OnInit=$OnInit."_mtypes_BuildMenu;";

# ------------------------------------------------------------------------------------------------------------------
$macroModules=$macroModules."mtypes;";

You made one mistake the internal mtypes needs to replaces with somethng like ublock or your macro interfere with the mtypes macro.

The ublock macro should be soemthing like the similar to the one below.

# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)

# ---------- UBlock Add Block Extension
-------------------------------------------------------------------
#
# Dependencies : main.kmm (OpenURL)
# Resources : -
# Preferences : -
#
# ------------------------------------------------------------------------------------------------------------------

ublock{
macroinfo=_("uBlock Add Blocker");
$OpenURL="chrome://ublock/content/dashboard.html"; &OpenURL_InNewWindow;
}

# ----- PRIVATE

_ublock_BuildMenu{
# edit menu
setmenu(Preferences,macro,"uBlock Add Blocker...",ublock);
}
$OnInit=$OnInit."_ublock_BuildMenu;";

# ------------------------------------------------------------------------------------------------------------------
$macroModules=$macroModules."ublock;"

Yes.grinning smiley

If You read my post carefully U would notice that I wrote replace all instances of mtypes with ublock using an editor that can do search and replace...

That prevents that You forget a string - which prevents that the two macros work side by side.

I also wrote that I did not edit that for him.


p.s. Sigh. I wanted soccerfan to have the chance to learn it. So that he can do it alone. It is such a nice, easy macro for a person that starts to learn it.
It was the first macro I adapted myself many years ago.

It was an instruction. You spoiled it. :mad:

I could have done it faster - than making up instructions. I wasted time. sad smiley



Edited 1 time(s). Last edit at 02/03/2015 08:38AM by guenter.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: rodocop
Date: February 03, 2015 11:28AM

George isn't reader. George is maker! grinning smiley

_________________________________________________________
You all are guys KM needs! But we should be more attentive to each other! :cool:

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: February 03, 2015 12:55PM

Quote
guenter
p.s. Sigh. I wanted soccerfan to have the chance to learn it. So that he can do it alone. It is such a nice, easy macro for a person that starts to learn it.
It was the first macro I adapted myself many years ago.

It was an instruction. You spoiled it. :mad:

I could have done it faster - than making up instructions. I wasted time. sad smiley

You did the right thing guenter smiling smiley I did end up making this macro:

# K-Meleon Macros (http://kmeleon.sourceforge.net/wiki/index.php?id=MacroLanguage)

# ---------- ublock -----------------------------------------------------------
#
# Dependencies : main.kmm (OpenURL)
# Resources : -
# Preferences : -
#
# ------------------------------------------------------------------------------

ublock{
$OpenURL="chrome://ublock/content/dashboard.html"; &OpenURL_InNewWindow;
}

# ----- PRIVATE

_ublock_BuildMenu{

# Creates a new "main menu" item that is called "Download Helper"
#setmenu(Main,popup,"&Extensions","&Help");
# edit menu
#setmenu("&Extensions",macro,"ublock",ublock);
setmenu(Preferences,macro,"ublock",ublock,-1);

}
$OnInit=$OnInit."_ublock_BuildMenu;";

# ----------------------------------------------------------------------------
$macroModules=$macroModules."ublock;";
_______________________________________________________

However, I cannot install ublock.xpi (or your attached check-compatibility...xpi).
What I did was to put ublock.xpi in the browser/extensions folder.
For good measure, I also unpacked the extension and put that in same folder.
When I click edit|ublock it brings up an empty page. No errors but no joy either.
I do have firefox compatability mode checked and
JamesD's extension installer macro is enabled.

Btw, I am on XP SP2 and my privacy toolbar is blank :mad:

soccerfan



Edited 1 time(s). Last edit at 02/03/2015 01:01PM by soccerfan.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: February 03, 2015 03:02PM

Update: I was finally able to see ublock in addons and make the macro work.

Quote
guenter
Tab 3rd party filter lists does constantly load. Console shows no error.:s

I can confirm.
That tab is important because it allows to select the
filters you want. Will have to wait for update to ublock.

Thanks to all for their help!

soccerfan

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: guenter
Date: February 03, 2015 06:08PM

Quote
soccerfan
Update: I was finally able to see ublock in addons and make the macro work.

Congratulations & welcome to the tinkers club. :cool:

p.s. I usually do not bother to install. I download and drop xpi into extensions.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: February 03, 2015 10:04PM

Quote
guenter
Congratulations & welcome to the tinkers club. :cool:

But forever an amateur grinning smiley

soccerfan

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Tnebi
Date: February 04, 2015 08:40PM

Since I followed this guide and installed the macro+the addon I want to know if it is working for you guys or not. Because it isn't working for me... Is it cause of the 3rd party filters?

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: George_Hall
Date: February 04, 2015 10:11PM

Quote
Tnebi
Since I followed this guide and installed the macro+the addon I want to know if it is working for you guys or not. Because it isn't working for me... Is it cause of the 3rd party filters?

You can not manual add websites to uBlock to block in Firefox.

So it is not possib;e to manually add websites to uBlock to Block in K-Meleon 74 and K-Meleon 75.

In Firefox, adding websittes to block with UBlock by clicking Icon and click on Block Elemnet Button. Then select elementt to block and click complete wiht ublock.

With future updates to uBlock it may be possible to manuaaly ad websites to Block.

Do not forget that uBlock for Firefox is still a work in prgress with somes bugs which why it is not listed on the Mozilla Addons for Firefox (https://addons.mozilla.org/) website.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Tnebi
Date: February 04, 2015 10:27PM

Yes I know you can't do those things... I'm just asking if the default options are working because it simply isn't working to me since it doesn't block anything.



Edited 1 time(s). Last edit at 02/04/2015 10:28PM by Tnebi.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: George_Hall
Date: February 05, 2015 12:14AM

I believe the default options for uBlock does not have any list of blocked websites.

So all the blocked websites would have to be created with Firefox to create a list of blocked ads for K-Meleon 75 and 75,

To use the list of blocked ads in K-Meleon 74 and 75, the folder extension-data with ublock.sqlite has to be copied from the Firefox Profile to the K-Meleon 74 and 75 Profile

This may be the only way for uBlock to block ads with K-Meleon 74 and 74, until ublock has the ability to manually block ads.



Edited 2 time(s). Last edit at 02/05/2015 12:17AM by George_Hall.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: George_Hall
Date: February 05, 2015 12:41AM

Quote
George_Hall
I believe the default options for uBlock does not have any list of blocked websites.

So all the blocked websites would have to be created with Firefox to create a list of blocked ads for K-Meleon 75 and 75,

To use the list of blocked ads in K-Meleon 74 and 75, the folder extension-data with ublock.sqlite has to be copied from the Firefox Profile to the K-Meleon 74 and 75 Profile

This may be the only way for uBlock to block ads with K-Meleon 74 and 74, until ublock has the ability to manually block ads.

it appears i was uBlock does have list of blocked websites which are store in the folder extension-data in the file ublock.sqlite.

So just copying the folder extension-data from the Firefox Profile into the K-Meleon Profile may make uBlock work with K-Meleon 74 and 75

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: February 05, 2015 01:33AM

Quote
George_Hall
So just copying the folder extension-data from the Firefox Profile into the K-Meleon Profile may make uBlock work with K-Meleon 74 and 75

Where exactly are you copying it to tke Kmeleon Profile folder? Thanks.

soccerfan

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: George_Hall
Date: February 05, 2015 08:05AM

Quote
soccerfan
Quote
George_Hall
So just copying the folder extension-data from the Firefox Profile into the K-Meleon Profile may make uBlock work with K-Meleon 74 and 75

Where exactly are you copying it to tke Kmeleon Profile folder? Thanks.

I mentioned that extension-datac contianins the file ublock.sqlite
http://kmeleonbrowser.org/forum/read.php?9,131872,131974#msg-131974

Which is created in the Firefox Profile (C:\Users\User Name\AppData\Roaming\Mozilla\Firefox\Profiles\xxxxxxx.default) when uBlock is installed.

If the file ublock.sqlite doess work, I can only think of three possible reasons why uBlock wll not work.

1, K-Meleon 74 and 75 can not find the file ublock.sqlite in the extension-data
Which you may be able to fix by test by copying ublock.sqlite to different locations in your K-Meleon Profile.

2. K-Meleon 74 and 75 can not read to the file ublock.sqlite. Whch I have no idea how to fix.

3. The list of uBlock wensites may be stored online instead of offline and takes to long for K-Meleon 74 and 75 to access them.



Edited 2 time(s). Last edit at 02/05/2015 08:10AM by George_Hall.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Tnebi
Date: February 05, 2015 09:21AM

I've tried to copy ublock.sqlite into my KMeleon profile folder, even tried to put it into an extension-data folder as in Firefox but it isn't working. So I guess there's something else we're missing ;D

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: George_Hall
Date: February 05, 2015 10:54AM

uBlock appears to be more complicated than Adblock Plus.

uBlock creates the file ublock.sqlite automatically with a list of addresses to block in Firefox.

uBlock must use some feature or system hook of Firefox to automatically download the data again and again to create to create the list in ublock.sqlite

I think K-Meleon 74 and 75 can not automatically download the lists in uBlock.

With Adblock Plus the lists are not downloaded automatically and are stored in a text file instead of sqlite file. So to accessing the list in Adblock Plus easier and faster than reading a sqlite file.

Besides the uBlock Extension is more than 4 times the size of Adblock Plus Extension.



Edited 1 time(s). Last edit at 02/05/2015 10:55AM by George_Hall.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Dorian
Date: February 05, 2015 08:20PM

You may have more luck with kmeleon 75b3.
The firefox version of ublock is a port of the chrome extension. Chrome extensions use a hidden window to do their stuff. Gecko has one but it wasn't created in previous version of kmeleon. That was the most obvious missing feature but maybe there are more.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Tnebi
Date: February 06, 2015 10:44AM

I've tried to use it in the new beta but it isn't working anyways...Anyone that is better than me can confirm it?

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: February 06, 2015 01:33PM

Quote
Tnebi
I've tried to use it in the new beta but it isn't working anyways...Anyone that is better than me can confirm it?

The km75b3 update allows me to install extensions. Now, ublock installs in
an 'extensions' folder created in 'Profiles/xxxxx.default'. Also created is
an 'extensions-data' folder that contains the file ublock.sqlite.

Unfortunately ublock is still not working for me. What guenter said earlier still happens:

Quote
guenter
Tab 3rd party filter lists does constantly load. Console shows no error.:s

Tried replacing ublock.sqlite by a working copy from FF35 but still no luck.

soccerfan



Edited 1 time(s). Last edit at 02/06/2015 01:43PM by soccerfan.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Tnebi
Date: February 12, 2015 03:11PM

Wish there was a way to get this awesome adblocker working sad smiley

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: ray
Date: July 09, 2015 12:20AM

From the developer of uBlock:

Quote
gorhill
What you may be experiencing is network delay when fetching https://raw.githubusercontent.com/gorhill/uBlock/master/assets/checksums.txt, which is what the 3rd-party filters pane does first, the first time you visit that pane.

https://github.com/gorhill/uBlock/issues/461#issuecomment-119630814

So it's likely that K-Meleon is having trouble fetching the checksums.txt file while on the 3rd-party filters pane.

Any idea why?



Edited 1 time(s). Last edit at 07/09/2015 12:20AM by ray.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: ray
Date: September 15, 2015 08:49PM

Just an update here, looks like Conkeror has the same issue as K-Meleon:
https://github.com/chrisaljoudi/uBlock/issues/827

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: 4td8s
Date: October 05, 2015 04:58PM

Quote
ray
Just an update here, looks like Conkeror has the same issue as K-Meleon:
https://github.com/chrisaljoudi/uBlock/issues/827

it looks like that issue isn't gonna be fixed anytime soon as nobody is assigned to fix the problem.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: soccerfan
Date: October 05, 2015 09:14PM

In the third post Dorian had planned to do something about it:
Quote
Dorian
This extension need a feature not available in current version. I'll add it in next update but don't know how it will work.

@Dorian: Hope you get the time to
update km75(or even km76) with his fix :drool:

Edit: Now, ublock is maintained as ublock.origin

soccerfan



Edited 2 time(s). Last edit at 10/05/2015 09:16PM by soccerfan.

Options: ReplyQuote
Re: ublock for kmeleon 75
Posted by: Dorian
Date: October 06, 2015 09:17AM

This is a different thing. What I was talking about was already added.
The issue in ublock tracker is talking about the same problem I mentionned with the patch for the password manager in 76 (e10s problem).

Unfortunately, mozilla implementation is so super megalicious abysmally idiotic that I'm not trying anything for now.

Options: ReplyQuote
Pages: 12Next
Current Page: 1 of 2


K-Meleon forum is powered by Phorum.