source: titan/plugins/imdbapi/imdbapi.c @ 18687

Last change on this file since 18687 was 18687, checked in by obi, 11 years ago

fix

File size: 1.2 KB
Line 
1#include "../titan/struct.h"
2#include "../titan/debug.h"
3#include "../titan/header.h"
4#include "imdbapi.h"
5
6char pluginname[] = "IMDb-API";
7char plugindesc[] = "Extensions";
8char pluginpic[] = "%pluginpath%/imdbapi/plugin.png";
9
10int pluginaktiv = 0;
11int pluginversion = PLUGINVERSION;
12struct skin* pluginmenu = NULL;
13int pluginflag = 0; //don't show the plugin in pluginmanager
14
15//wird beim laden ausgefuehrt
16void init(void)
17{
18        pluginaktiv = 1;
19        char* tmpstr = NULL;
20        struct skin* mainmenu = getscreen("mainmenu");
21        struct skin* listbox = getscreennode(mainmenu, "listbox");
22        struct skin* child = NULL;
23
24        if(mainmenu == NULL || listbox == NULL)
25                return;
26
27        child = getscreennode(mainmenu, "imdbapi");
28        if(child != NULL)
29                changeinput(child, "start");
30
31        pluginmenu = child;
32        tmpstr = ostrcat(getconfig("pluginpath", NULL), "/imdbapi/skin.xml", 0, 0);
33        readscreen(tmpstr, 201, 1);
34        free(tmpstr); tmpstr = NULL;
35        debug(10, "imdbapi Plugin loadet !!!");
36}
37
38//wird beim entladen ausgefuehrt
39void deinit(void)
40{
41        delmarkedscreen(201);
42        pluginaktiv = 0;
43        debug(10, "imdbapi Plugin removed !!!");
44}
45
46//wird in der Pluginverwaltung bzw Menue ausfeguehrt
47void start(void)
48{
49        screenimdbapi(NULL, NULL, NULL, NULL, NULL);
50}
Note: See TracBrowser for help on using the repository browser.