issue 1
(Segmentation Fault) commented on by jiri.dudek
- I found workaround for this bug. The initialization of gears have to be performed in
the page, so :
1)Inject the initialization script into the page. The guideline can be found at
http://wiki.greasespot.net/UnsafeWindow#Alternatives_to_unsafeWindow.
2)In the initialization script put the result object (gears db or whatever) at
window.gearsDBResult in case of error set window.gearsError.
3)In greasemonkey script wait for the results window.gearsDBResult or
window.gearsError. U may found inspiration in this script :
// Check if jQuery's loaded
function GM_wait() {
if(!typeof unsafeWindow.gearsDBError == 'undefined'){return;}
else if(typeof unsafeWindow.gearsDB == 'undefined') {
window.setTimeout(GM_wait,100); }
else if(typeof unsafeWindow.jQuery == 'undefined') {
window.setTimeout(GM_wait,100); }
else { $ = unsafeWindow.jQuery; jQuery= unsafeWindow.jQuery; jQuery(letsJQuery);
}
}
/*
Following script is injected to the page to prevent segmentation fault during
*/
function createGears() {
if (!window.google) google= {};
if (!google.gears){
try{
google.gears= {factory: new GearsFactory()};
} catch(e) {
window.gearsDBError = e;
}
}
try{
var db = google.gears.factory.create('beta.database', '1.0');
if (db) {
db.open('UU');
window.gearsDB = db;
}
} catch(e) {
window.gearsDBError = e;
}
}
var script = document.createElement("script");
script.type = "application/javascript";
script.textContent = "(" + createGears + ")();";
document.body.appendChild(script);
GM_wait();
I found workaround for this bug. The initialization of gears have to be performed in
the page, so :
1)Inject the initialization script into the page. The guideline can be found at
http://wiki.greasespot.net/UnsafeWindow#Alternatives_to_unsafeWindow.
2)In the initialization script put the result object (gears db or whatever) at
window.gearsDBResult in case of error set window.gearsError.
3)In greasemonkey script wait for the results window.gearsDBResult or
window.gearsError. U may found inspiration in this script :
// Check if jQuery's loaded
function GM_wait() {
if(!typeof unsafeWindow.gearsDBError == 'undefined'){return;}
else if(typeof unsafeWindow.gearsDB == 'undefined') {
window.setTimeout(GM_wait,100); }
else if(typeof unsafeWindow.jQuery == 'undefined') {
window.setTimeout(GM_wait,100); }
else { $ = unsafeWindow.jQuery; jQuery= unsafeWindow.jQuery; jQuery(letsJQuery);
}
}
/*
Following script is injected to the page to prevent segmentation fault during
*/
function createGears() {
if (!window.google) google= {};
if (!google.gears){
try{
google.gears= {factory: new GearsFactory()};
} catch(e) {
window.gearsDBError = e;
}
}
try{
var db = google.gears.factory.create('beta.database', '1.0');
if (db) {
db.open('UU');
window.gearsDB = db;
}
} catch(e) {
window.gearsDBError = e;
}
}
var script = document.createElement("script");
script.type = "application/javascript";
script.textContent = "(" + createGears + ")();";
document.body.appendChild(script);
GM_wait();
Nov 23, 2009
issue 1
(Segmentation Fault) commented on by jiri.dudek
- The problem appears when you call : "unsafeWindow.google.gears= {factory: new
GearsFactory()};" in grease monkey script in ubuntu. I don't know how to fix that but
any help would be nice . :D
The problem appears when you call : "unsafeWindow.google.gears= {factory: new
GearsFactory()};" in grease monkey script in ubuntu. I don't know how to fix that but
any help would be nice . :D
May 24, 2009
issue 1
(Segmentation Fault) commented on by ward.dav...@gmail.com
- Ubuntu distro based Firefox 3.0.9
GreaseMonkey version - Latest
Gears - Latest
Exact same issue. Appears bug reporter is running from windows, I'm on Ubuntu 9.04.
Ubuntu distro based Firefox 3.0.9
GreaseMonkey version - Latest
Gears - Latest
Exact same issue. Appears bug reporter is running from windows, I'm on Ubuntu 9.04.
Oct 22, 2008
issue 2
(Offline Wikipedia on the left side) reported by tagno25
- Not really an issue, I just cannot figure out a different way to submit
this info.
change
var links = document.getElementsByTagName('h1');
to
var links = document.getElementsByClassName("portlet");
and change
links[0].insertBefore(offlineControlsDiv, links[0].firstChild);
to
links[links.length-1].appendChild(offlineControlsDiv,
links[links.length-1].firstChild);
to place the saved page list on the left side of the page
Not really an issue, I just cannot figure out a different way to submit
this info.
change
var links = document.getElementsByTagName('h1');
to
var links = document.getElementsByClassName("portlet");
and change
links[0].insertBefore(offlineControlsDiv, links[0].firstChild);
to
links[links.length-1].appendChild(offlineControlsDiv,
links[links.length-1].firstChild);
to place the saved page list on the left side of the page
Sep 08, 2008
r20
(Significant updates to work with Gears 0.4) committed by lisbakke
- Significant updates to work with Gears 0.4
issue 1
(Segmentation Fault) reported by davmillar
- 1. Enable GearsMonkey script.
2. Visit a page from Wikipedia.
3. If necessary, allow the web site to access Google Gears.
Almost immediately, Firefox crashes. By running the program from a terminal
window I see that there was a segmentation fault.
I am using the mist up to date copies of Google Gears, GreaseMonkey, and
GearsMonkey using Firefox 3 on Ubuntu 8.04.
Google Gears has worked with Google Reader, so I do not believe that the
problem lies with Gears itself, but I may be wrong.
1. Enable GearsMonkey script.
2. Visit a page from Wikipedia.
3. If necessary, allow the web site to access Google Gears.
Almost immediately, Firefox crashes. By running the program from a terminal
window I see that there was a segmentation fault.
I am using the mist up to date copies of Google Gears, GreaseMonkey, and
GearsMonkey using Firefox 3 on Ubuntu 8.04.
Google Gears has worked with Google Reader, so I do not believe that the
problem lies with Gears itself, but I may be wrong.