Re: How to invalidate entries in the cache

2006-05-11 Thread Michel Gutierrez
Christian Biesinger wrote: That error is NS_ERROR_CACHE_KEY_NOT_FOUND. Try http://silver.warwickcompsoc.co.uk/~silver/mozilla/misc/nserror - unfortunately XPConnect knows very few error codes, so its error messages aren't always helpful. Thank you Christian. This is definitely an address to

Re: Does xpcom can fire an event???

2006-05-11 Thread Christian Biesinger
huazilin wrote: But, Can I define event by myself? How to define??All the DOM event types which I have known don't meet my request. And I also don't know how to fire an user defined event in the c++ xpcom. Since your webpage seemingly has XPConnect privileges, maybe it can register itself as a

Re: How to invalidate entries in the cache

2006-05-11 Thread Christian Biesinger
Michel Gutierrez wrote: [Exception... "Component returned failure code: 0x804b003d [nsICacheSession.openCacheEntry]" nsresult: "0x804b003d ()" location: "JS frame :: chrome://victor/content/vutil.js :: anonymous :: line 1542" data: no] That error is NS_ERROR_CACHE_KEY_NOT_FOUND. Try http:/

Re: How to invalidate entries in the cache

2006-05-11 Thread Michel Gutierrez
Thank you Darin. I have tried that already and I get an exception while calling nsICacheSession.openCacheEntry: [Exception... "Component returned failure code: 0x804b003d [nsICacheSession.openCacheEntry]" nsresult: "0x804b003d ()" location: "JS frame :: chrome://victor/content/vutil.js :: a

Re: How to invalidate entries in the cache

2006-05-11 Thread Darin Fisher
Try opening the cache entry after the visitor completes. You cannot open cache entries while visiting the cache. Save a list of entries keys (and cache client IDs) that you wish to doom, and then doom them after you finish visiting. -Darin On 5/11/06, Michel Gutierrez <[EMAIL PROTECTED]> wrote

How to invalidate entries in the cache

2006-05-11 Thread Michel Gutierrez
Hi all, From my chrome application, I need to invalidate some cache entries of HTML files, in order to make those pages be reloaded next time they are displayed. I use my own instance of nsICacheVisitor to walk through cached entries, and I can locate the desired entries. However, the nsICa

How to determine that element belongs to data source?

2006-05-11 Thread Alexander Dyagilev
The code below works fine. However, observer is called not only for global history elements, displayed in Ctrl+H, but for some other elements. So the problem is to determine that element belongs to "NC:HistoryRoot" data store. QUESTION: How to do this? var histListener = { onAssert: function