File AppWindow.xml changed (mode: 100755) (index ac82708..0f65b59) |
17 |
17 |
<hgroup> |
<hgroup> |
18 |
18 |
<listview id="lv3" frame="readlist" notify="appmessage" weight="50"><column/></listview> |
<listview id="lv3" frame="readlist" notify="appmessage" weight="50"><column/></listview> |
19 |
19 |
<vgroup> |
<vgroup> |
20 |
|
<text id="channel_title" PreParse="\33b"></text> |
|
21 |
|
<text id="channel_description"></text> |
|
|
20 |
|
<text id="channel_title" PreParse="\33b"/> |
|
21 |
|
<text id="channel_description"/> |
22 |
22 |
|
|
23 |
|
<listview id="articles" notify="appmessage"> |
|
|
23 |
|
<listview id="articles" notify="active"> |
24 |
24 |
<column title="Title"/> |
<column title="Title"/> |
25 |
25 |
<column title="PubDate"/> |
<column title="PubDate"/> |
26 |
26 |
<column title="Category"/> |
<column title="Category"/> |
27 |
|
|
|
28 |
|
</listview> |
|
29 |
|
<floattext id="textfield" background="readlistback" tabsize="4" justify="true"> |
|
|
27 |
|
</listview> |
|
28 |
|
|
|
29 |
|
<text id="item_title" PreParse="\33b"/> |
|
30 |
|
<floattext id="textfield" background="readlistback" tabsize="4" justify="true"> |
30 |
31 |
|
|
31 |
32 |
</floattext> |
</floattext> |
32 |
33 |
|
|
File IvoRSS.hws changed (mode: 100755) (index 47ae817..ee41046) |
... |
... |
Function p_MUIEvent(msg) |
38 |
38 |
Case "menu_muisettings": |
Case "menu_muisettings": |
39 |
39 |
mui.DoMethod("app", "OpenConfigWindow") |
mui.DoMethod("app", "OpenConfigWindow") |
40 |
40 |
EndSwitch |
EndSwitch |
|
41 |
|
Case "Listview": |
|
42 |
|
;assert(msg.Attribute = "Active") |
|
43 |
|
;assert(msg.ID = "articles") |
|
44 |
|
Local chosen_item = items_list[msg.TriggerValue] |
|
45 |
|
mui.Set("item_title", "Contents", chosen_item.title) |
|
46 |
|
mui.Set("textfield", "Text", chosen_item.description) |
|
47 |
|
;Switch msg.ID |
|
48 |
|
;Case "CloseRequest": |
|
49 |
|
; End |
|
50 |
|
;EndSwitch |
41 |
51 |
EndSwitch |
EndSwitch |
42 |
52 |
EndFunction |
EndFunction |
43 |
53 |
|
|
|
... |
... |
url$ = "https://www.powerpc-notebook.org/en/feed/" |
55 |
65 |
DownloadFile(url$, {File = "feed.xml", Adapter = "hurl"}) |
DownloadFile(url$, {File = "feed.xml", Adapter = "hurl"}) |
56 |
66 |
|
|
57 |
67 |
text$ = FileToString("feed.xml") |
text$ = FileToString("feed.xml") |
58 |
|
mui.Set("textfield", "Text", text$) |
|
|
68 |
|
;mui.Set("textfield", "Text", text$) |
59 |
69 |
|
|
|
70 |
|
|
|
71 |
|
items_list = CreateList() |
60 |
72 |
channel_level = True |
channel_level = True |
61 |
73 |
current_element$ = Nil |
current_element$ = Nil |
62 |
74 |
|
|
63 |
|
current_item = {title="", pubdate="", category=""} |
|
|
75 |
|
current_item = {title="", pubdate="", category="", description=""} |
64 |
76 |
|
|
65 |
77 |
Function StartElement(p, name$, attrs) |
Function StartElement(p, name$, attrs) |
66 |
78 |
current_element$ = name$ |
current_element$ = name$ |
|
... |
... |
Function EndElement(p, name$) |
82 |
94 |
current_item.title, |
current_item.title, |
83 |
95 |
current_item.pubdate, |
current_item.pubdate, |
84 |
96 |
current_item.category) |
current_item.category) |
85 |
|
current_item = {title="", pubdate="", category=""} |
|
|
97 |
|
InsertItem(items_list, current_item) |
|
98 |
|
current_item = {title="", pubdate="", category="", description=""} |
86 |
99 |
EndIf |
EndIf |
87 |
100 |
EndFunction |
EndFunction |
88 |
101 |
|
|
|
... |
... |
Function CharacterData(p, str$) |
95 |
108 |
else |
else |
96 |
109 |
If current_element$ = "title" Then current_item.title = str$ |
If current_element$ = "title" Then current_item.title = str$ |
97 |
110 |
If current_element$ = "pubDate" Then current_item.pubdate = str$ |
If current_element$ = "pubDate" Then current_item.pubdate = str$ |
|
111 |
|
If current_element$ = "description" Then current_item.description = str$ |
98 |
112 |
If current_element$ = "category" |
If current_element$ = "category" |
99 |
113 |
If current_item.category = "" |
If current_item.category = "" |
100 |
114 |
current_item.category = str$ |
current_item.category = str$ |