Mark as Watched - MyVideos60.db and Files Table

  Thread Rating:
  • 0 Votes - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Post Reply
jmarshall Offline
Team-XBMC Developer
Posts: 24,523
Joined: Oct 2003
Reputation: 138
Post: #11
list.setContent("movies") from the plugin.

Always read the XBMC online-manual, FAQ and search the forum before posting.
Do not e-mail XBMC-Team members directly asking for support. Read/follow the forum rules.
For troubleshooting and bug reporting please make sure you read this first.


[Image: badge.gif]
find quote
bengalih Offline
Senior Member
Posts: 117
Joined: Oct 2004
Reputation: 1
Post: #12
Thanks again for the response jmarshall.

I am unable to find any information at all about the list.setContent command.

I have verified that throughout the script the following command is used:

Code:
xbmcplugin.setContent(int(sys.argv[1]),'Movies')

For example here is the routine to enumerate the user's netflix instant queue:

Code:
def getInstantQueue(displayWhat=None):
    initApp()
    getUserInstantQueue(netflixClient,user, displayWhat)
    if(not user):
        exit
    time.sleep(1)
    xbmcplugin.addSortMethod( handle=int( sys.argv[ 1 ] ), sortMethod=xbmcplugin.SORT_METHOD_LABEL )
    xbmcplugin.addSortMethod( handle=int( sys.argv[ 1 ] ), sortMethod=xbmcplugin.SORT_METHOD_DATE )
    xbmcplugin.addSortMethod( handle=int( sys.argv[ 1 ] ), sortMethod=xbmcplugin.SORT_METHOD_VIDEO_RUNTIME )
    xbmcplugin.addSortMethod( handle=int( sys.argv[ 1 ] ), sortMethod=xbmcplugin.SORT_METHOD_VIDEO_YEAR )
    xbmcplugin.addSortMethod( handle=int( sys.argv[ 1 ] ), sortMethod=xbmcplugin.SORT_METHOD_GENRE )
    xbmcplugin.addSortMethod( handle=int( sys.argv[ 1 ] ), sortMethod=xbmcplugin.SORT_METHOD_MPAA_RATING )
    xbmcplugin.setContent(int(sys.argv[1]),;'Movies')
    xbmcplugin.endOfDirectory(int(sys.argv[1]))

This def calls upon the getUserInstantQueue def which in turn calls upon def getMovieDataFromFeed which will eventually add each item to the plugin menu with commands similar to:

Code:
xbmcplugin.addDirectoryItem(handle=int(sys.argv[1]),url=url, listitem=li, isFolder=isFolder)

I can only assume the setContent method of the xbmcplugin is the same as the list.setcontent you provided? The addDirectoryItem method is the only place in the code that I can see any interface being done directly with the library.

Once again, please excuse my ignorance on the subject...this is a much desired feature that has ceased to function since the upgrade to Eden, and many of the users of this plugin are itching to get it working again.

Perhaps there is more to the setcontent that I don't yet understand (that would have changed since Dharma) and that this is still the reason. Or perhaps there is another aspect that is causing this.

Is there any other guidance you can offer?

thanks.

.peace out.
(This post was last modified: 2012-05-22 02:08 by bengalih.)
find quote
bengalih Offline
Senior Member
Posts: 117
Joined: Oct 2004
Reputation: 1
Post: #13
Looking at some other plugins (like funny or die) I see a completely different set of syntax being used.

Whereas in XBMCFlicks the strPath looks like this:

C:\Users\username\AppData\Roaming\XBMC\userdata\addon_data\plugin.video.xbmcflic​ks\links\

and the strFilename looks like:

70196252.html

In other plugins they are more similar to:

strPath:
plugin://plugin.video.funny.or.die/

strFilename:
plugin://plugin.video.funny.or.die/?url=11565f67bc&mode=2&name=The+King+Kaiser+Show+from+jeffhin

Now I realize that these other plugins don't write out external file links like XBMCFlicks does (or at least I don't believe them to), but I can't find any documentation that discussed the proper methods of adding and what any of this means.

I know that a lot of this code is beyond me, but I find it hard to believe that a plugin which worked fine in this regard in dharma now has the functionality completely broken in Eden with absolutely no documentation to describe what changes occurred and how to properly code for them.

Perhaps I am missing some important info, but after hours of scouring the web using the most common to most obscure terms I am still left with virtually no information about how all of this fits together.

I am hoping someone can at least craft me what the proper entry in the database should be. If I can hand edit a db entry which will properly reflect in the GUI for a watched episode, then I can go back to the code and look to having it write it there properly - but at this point I can't find any info on the proper syntactical entries.

once again, thanks for any assitance....

.peace out.
find quote
Bstrdsmkr Offline
Fan
Posts: 651
Joined: Oct 2010
Reputation: 12
Post: #14
Urls like
Quote:plugin://plugin.video.funny.or.die/?url=11565f67bc&mode=2&name=The+King+Kaiser+Show+from+jeffhin
are used to launch plugins which find the content again (based) on the parameters sent to them and then play the content.

Since xbmcflix plays through a browser, I would imagine that it's just saving the webpage to a file, then opening that file in a browser when called. If that's the case, and the url for a particular piece of content never changes, you just need to look that file up in the database and set the playcount higher than 1
find quote
Post Reply