Re: [gedit-list] Snapopen plugin updated with filebrowser support



Hi Mads,

I download the code, and just I used the same aproach to solve the problem. 
For your code the only change is that statement, added gedit to the
tab_get_from_document:

		if doc.get_uri() == uri:
			return gedit.gedit_tab_get_from_document(doc)

and this functions ok, and the multiple selection work fine for me, I love
this plugins more and more...

thank's you. From the users of gedit 2.14 :-D

La Serena,
Chile



Mads Buus Jensen wrote:
> 
> Hi Warlock,
> 
> Cool! I think I will post your findings on my page, to help 2.14 users
> use my plugin. Now that you mention it, I saw a deprecation warning when
> running the eddt about get_encoding stuff.., avoiding this in my plugin
> I probably stepped into 2.16 land.
> 
>>From reading your link, the 'get_tab_from_uri' you should be homemade by
> something like this:
> 
> -------------------
> 
> #gedit < 2.16 version
> def get_tab_from_uri(self, window, uri):
> 	docs = window.get_documents()
> 	for doc in docs:
> 		if doc.get_uri() == uri:
> 			return gedit.tab_get_from_document(doc)
> 	return None
> 
> --------------------
> 
> I have attached a 2.14 version of __init__.py that you can use (with the
> above two changes (commented). I have not tried it on 2.14, but I have
> succesfully tested homemade reimpl of get_tab_from_uri on 2.16
> 
> 
> Looking forward to hearing if it helps you.
> 
> Regards,
> Mads
> 
> 
> 
> 
> On Fri, 2006-12-01 at 13:37 -0800, Warlock-G wrote:
>> Hi,
>> 
>> for the first error I fix it with gedit_encoding_get_current(), and run
>> ok
>> 
>> 
>> for the second error, I found this 
>> 
>> http://www.archivesat.com/discussion_about_usage_and_developement_of_gedit/thread999490.htm
>> get_tab_from_uri 
>> 
>> This one has been binded after the 2.15.3 release
>> 
>> 
>> bye
>> 
>> 
> _______________________________________________
> gedit-list mailing list
> gedit-list gnome org
> http://mail.gnome.org/mailman/listinfo/gedit-list
> 
> 

-- 
View this message in context: http://www.nabble.com/New-cool-plugin-for-Gedit-tf2458473.html#a7676084
Sent from the Gnome - Gedit mailing list archive at Nabble.com.




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]