The branch, dharma has been updated
       via  a00b24116ef23a7a36ca5daaf45ccad36cb3fdf7 (commit)
      from  bb815a34ec45c88713e1f4d63cc32b2360ee1514 (commit)

- Log -----------------------------------------------------------------
http://xbmc.git.sourceforge.net/git/gitweb.cgi?p=xbmc/plugins;a=commit;h=a00b24116ef23a7a36ca5daaf45ccad36cb3fdf7

commit a00b24116ef23a7a36ca5daaf45ccad36cb3fdf7
Author: spiff <[email protected]>
Date:   Mon Sep 26 09:10:59 2011 +0200

    [plugin.video.wimp] updated to version 0.6

diff --git a/plugin.video.wimp/addon.xml b/plugin.video.wimp/addon.xml
index d6ac337..aa2d80e 100644
--- a/plugin.video.wimp/addon.xml
+++ b/plugin.video.wimp/addon.xml
@@ -1,7 +1,7 @@
 <?xml version="1.0" encoding="UTF-8" standalone="yes"?>
 <addon id="plugin.video.wimp"
        name="Wimp.com"
-       version="0.5"
+       version="0.6"
        provider-name="Insayne">
   <requires>
     <import addon="xbmc.python" version="1.0"/>
@@ -12,7 +12,7 @@
   </extension>
   <extension point="xbmc.addon.metadata">
     <platform>all</platform>
-    <summary>Stream Wimp.com</summary>
+    <summary>Stream Wimp.com Content</summary>
     <description>The Content of Wimp.com on your Media Center</description>
   </extension>
 </addon>
diff --git a/plugin.video.wimp/changelog.txt b/plugin.video.wimp/changelog.txt
index bf5c4f3..d6ab3a1 100644
--- a/plugin.video.wimp/changelog.txt
+++ b/plugin.video.wimp/changelog.txt
@@ -1,3 +1,7 @@
+0.6

+- Fixed: Navigation of addon (Adherred to the changes of wimp.com)

+- Added: Archive Browser

+

 0.5

 - Fixed: XBMC Compilance change: No longer using os.getcwd()

 

diff --git a/plugin.video.wimp/default.py b/plugin.video.wimp/default.py
index ca0ffe2..d05d04f 100644
--- a/plugin.video.wimp/default.py
+++ b/plugin.video.wimp/default.py
@@ -9,7 +9,7 @@ __plugin__ = "Wimp.com"
 __author__ = "Insayne"

 __url__ = "http://code.google.com/p/insayne-projects/";

 __svn_url__ = 
"https://insayne-projects.googlecode.com/svn/trunk/XBMC/Video/plugin.video.wimp/";

-__version__ = "0.4"

+__version__ = "0.6"

 __svn_revision__ = "$Revision$"

 __XBMC_Revision__ = xbmc.getInfoLabel('System.BuildVersion')

 __settings__ = xbmcaddon.Addon(id='plugin.video.wimp')

@@ -36,16 +36,42 @@ def Generate_Index():
                addVideo(title,link,1, thumb)

 

        root_path = xbmc.translatePath(__settings__.getAddonInfo('path'))

-       thumb = xbmc.translatePath(os.path.join( root_path, 'resources', 
'images', 'back.png'))

+       thumb = xbmc.translatePath(os.path.join( root_path, 'resources', 
'images', 'archives.png'))

        link = '1'

-       title = "<< Page (1)"

-       addDir(title,link,2, thumb)

+       title = "[Archives]"

+       addDir(title,link,3, thumb)

+

+def get_archives():

+       # Request the Page

+       url = 'http://wimp.com/archives/'

+       req = urllib2.Request(url)

+       response = urllib2.urlopen(req)

+       html=response.read()

+       response.close()

+       html = html.replace("\n", "")

+       html = html.replace("\r", "")

+       thumb = ''

+       regex = '<a class="b" href="(.+?)">(.+?)</a><br/>'

+       videos = re.compile(regex).findall(html)

        

-def Generate_Page(pagenum):

-       next_page = pagenum + 1

+

+       

+       for link,title in videos:

+               link = 'http://wimp.com' + link

+               title = cleanstring(remove_spaces(title))

+               addDir(title,link,2, thumb)

        

+       # Link back to Current Month

+       root_path = xbmc.translatePath(__settings__.getAddonInfo('path'))

+       thumb = xbmc.translatePath(os.path.join( root_path, 'resources', 
'images', 'back.png'))

+       link = ""

+       title = "<< Back to Current Month"

+       addDir(title,link,4, thumb)

+

+

+def Generate_archive_page(link):

        # Request the Page

-       url = 'http://wimp.com/' + str(pagenum)

+       url = str(link)

        req = urllib2.Request(url)

        response = urllib2.urlopen(req)

        html=response.read()

@@ -62,10 +88,11 @@ def Generate_Page(pagenum):
                addVideo(title,link,1, thumb)

        

        root_path = xbmc.translatePath(__settings__.getAddonInfo('path'))

-       thumb = xbmc.translatePath(os.path.join( root_path, 'resources', 
'images', 'back.png'))

-       link = str(next_page)

-       title = "<< Page (" + str(next_page) + ")"

-       addDir(title,link,2, thumb)

+       thumb = xbmc.translatePath(os.path.join( root_path, 'resources', 
'images', 'archives.png'))

+       link = ""

+       title = "<< Back to Archives Listing"

+       addDir(title,link,3, thumb)

+       

        

 def Play_Video(url):

        global set_video_type

@@ -193,9 +220,13 @@ elif mode==1:
                xbmcplugin.setResolvedUrl(int(sys.argv[1]), True, li)

 

 elif mode==2:

-       page_number = int(url)

-       Generate_Page(page_number)

+       Generate_archive_page(url)

 

+elif mode==3:

+       get_archives()

 

+elif mode==4:

+       Generate_Index()

+       

 xbmcplugin.setContent(handle=int(sys.argv[1]), content="movies" )

 xbmcplugin.endOfDirectory(int(sys.argv[1]))


-----------------------------------------------------------------------

Summary of changes:
 plugin.video.wimp/addon.xml                     |    4 +-
 plugin.video.wimp/changelog.txt                 |    4 ++
 plugin.video.wimp/default.py                    |   57 +++++++++++++++++-----
 plugin.video.wimp/resources/images/archives.png |  Bin 0 -> 49407 bytes
 4 files changed, 50 insertions(+), 15 deletions(-)
 create mode 100644 plugin.video.wimp/resources/images/archives.png


hooks/post-receive
-- 
Plugins

------------------------------------------------------------------------------
All the data continuously generated in your IT infrastructure contains a
definitive record of customers, application performance, security
threats, fraudulent activity and more. Splunk takes this data and makes
sense of it. Business sense. IT sense. Common sense.
http://p.sf.net/sfu/splunk-d2dcopy1
_______________________________________________
Xbmc-addons mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xbmc-addons

Reply via email to