Skip to content

Commit

Permalink
Merge pull request #283 from phunkyfish/multiple-instances-omega
Browse files Browse the repository at this point in the history
Add support for multiple backends
  • Loading branch information
phunkyfish authored Feb 12, 2023
2 parents 464ba4c + ca8eb6f commit 209fc0a
Show file tree
Hide file tree
Showing 19 changed files with 619 additions and 341 deletions.
7 changes: 6 additions & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ set(VBOX_SOURCES
src/VBoxInstance.cpp)

set(VBOX_SOURCES_VBOX
src/vbox/AddonSettings.h
src/vbox/AddonSettings.cpp
src/vbox/CategoryGenreMapper.h
src/vbox/CategoryGenreMapper.cpp
src/vbox/Channel.h
Expand All @@ -29,13 +31,16 @@ set(VBOX_SOURCES_VBOX
src/vbox/Exceptions.h
src/vbox/GuideChannelMapper.h
src/vbox/GuideChannelMapper.cpp
src/vbox/InstanceSettings.h
src/vbox/InstanceSettings.cpp
src/vbox/Recording.h
src/vbox/Recording.cpp
src/vbox/RecordingReader.cpp
src/vbox/RecordingReader.h
src/vbox/SeriesRecording.h
src/vbox/SeriesRecording.cpp
src/vbox/Settings.h
src/vbox/SettingsMigration.h
src/vbox/SettingsMigration.cpp
src/vbox/SoftwareVersion.h
src/vbox/SoftwareVersion.cpp
src/vbox/StartupStateHandler.h
Expand Down
1 change: 0 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,6 @@ Settings related to Channels & EPG.
- `LCN (Logical Channel Number) from backend` - The channel numbers as set on the backend.
- `Channel index in backend` - Starting from 1 number the channels as per the order they appear on the backend.
* **Reminder time (minutes before programme start)**: The amount of time in minutes prior to a programme start that a reminder should pop up.
* **Skip initial EPG load**: Ignore the initial EPG load. Enabled by default to prevent crash issues on LibreElec/CoreElec.

### Timeshift
Settings related to the timeshift.
Expand Down
2 changes: 1 addition & 1 deletion pvr.vbox/addon.xml.in
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="pvr.vbox"
version="21.0.0"
version="21.1.0"
name="VBox TV Gateway PVR Client"
provider-name="Sam Stenvall">
<requires>@ADDON_DEPENDS@</requires>
Expand Down
4 changes: 4 additions & 0 deletions pvr.vbox/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,7 @@
v21.1.0
- Add support for multiple backends
- Remove skip intial EPG, no longer required in Kodi Nexus

v20.3.0
- Kodi inputstream API update to version 3.2.0
- Kodi PVR API update to version 8.0.2
Expand Down
157 changes: 157 additions & 0 deletions pvr.vbox/resources/instance-settings.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,157 @@
<?xml version="1.0" encoding="utf-8" ?>
<settings version="1">
<section id="addon" help="-1">

<!-- Connection -->
<category id="connection" label="30006" help="30600">
<group id="1" label="30000">
<setting id="hostname" type="string" label="30001" help="30601">
<level>0</level>
<default></default>
<constraints>
<allowempty>true</allowempty>
</constraints>
<control type="edit" format="string" />
</setting>
<setting id="http_port" type="integer" label="30002" help="30602">
<level>1</level>
<default>80</default>
<constraints>
<minimum>1</minimum>
<step>1</step>
<maximum>65535</maximum>
</constraints>
<control type="edit" format="integer" />
</setting>
<setting id="https_port" type="integer" label="30005" help="30603">
<level>2</level>
<default>0</default>
<constraints>
<minimum>0</minimum>
<step>1</step>
<maximum>65535</maximum>
</constraints>
<control type="edit" format="integer" />
</setting>
<setting id="upnp_port" type="integer" label="30003" help="30604">
<level>2</level>
<default>55555</default>
<constraints>
<minimum>1</minimum>
<step>1</step>
<maximum>65535</maximum>
</constraints>
<control type="edit" format="integer" />
</setting>
<setting id="connection_timeout" type="integer" label="30004" help="30605">
<level>3</level>
<default>3</default>
<constraints>
<minimum>1</minimum>
<step>1</step>
<maximum>60</maximum>
</constraints>
<control type="slider" format="integer">
<popup>true</popup>
<formatlabel>14045</formatlabel>
</control>
</setting>
</group>
<group id="2" label="30007">
<setting id="external_hostname" type="string" label="30001" help="30606">
<level>2</level>
<default></default>
<constraints>
<allowempty>true</allowempty>
</constraints>
<control type="edit" format="string" />
</setting>
<setting id="external_http_port" type="integer" label="30002" help="30607">
<level>2</level>
<default>19999</default>
<constraints>
<minimum>1</minimum>
<step>1</step>
<maximum>65535</maximum>
</constraints>
<control type="edit" format="integer" />
</setting>
<setting id="external_https_port" type="integer" label="30005" help="30608">
<level>2</level>
<default>0</default>
<constraints>
<minimum>0</minimum>
<step>1</step>
<maximum>65535</maximum>
</constraints>
<control type="edit" format="integer" />
</setting>
<setting id="external_upnp_port" type="integer" label="30003" help="30609">
<level>2</level>
<default>55555</default>
<constraints>
<minimum>1</minimum>
<step>1</step>
<maximum>65535</maximum>
</constraints>
<control type="edit" format="integer" />
</setting>
<setting id="external_connection_timeout" type="integer" label="30004" help="30610">
<level>3</level>
<default>10</default>
<constraints>
<minimum>1</minimum>
<step>1</step>
<maximum>60</maximum>
</constraints>
<control type="slider" format="integer">
<popup>true</popup>
<formatlabel>14045</formatlabel>
</control>
</setting>
</group>
</category>

<!-- Channels & EPG -->
<category id="epg" label="30020" help="30620">
<group id="1" label="30021">
<setting id="set_channelid_using_order" type="integer" label="30023" help="30621">
<level>0</level>
<default>0</default>
<constraints>
<options>
<option label="30024">0</option> <!-- LCN -->
<option label="30025">1</option> <!-- BACKEND ORDER -->
</options>
</constraints>
<control type="list" format="integer" />
</setting>
</group>
</category>

<!-- Timeshift -->
<category id="timeshift" label="30040" help="30640">
<group id="1" label="30040">
<setting id="timeshift_enabled" type="boolean" label="30041" help="30641">
<level>0</level>
<default>false</default>
<control type="toggle" />
</setting>
<setting id="timeshift_path" type="path" parent="timeshift_enabled" label="30042" help="30642">
<level>2</level>
<default>special://userdata/addon_data/pvr.vbox</default>
<constraints>
<allowempty>true</allowempty>
<writable>true</writable>
</constraints>
<dependencies>
<dependency type="enable" setting="timeshift_enabled" operator="is">true</dependency>
</dependencies>
<control type="button" format="path">
<heading>657</heading>
</control>
</setting>
</group>
</category>
</section>
</settings>
Original file line number Diff line number Diff line change
Expand Up @@ -89,11 +89,7 @@ msgctxt "#30026"
msgid "Reminder time (minutes before program starts)"
msgstr ""

msgctxt "#30027"
msgid "Skip initial EPG load"
msgstr ""

#empty strings from id 30028 to 30039
#empty strings from id 30027 to 30039

msgctxt "#30040"
msgid "Timeshift"
Expand Down Expand Up @@ -205,7 +201,7 @@ msgstr ""
#empty strings from id 30624 to 30639

msgctxt "#30640"
msgid "Settings related to the timeshift."
msgid "Settings related to timeshift."
msgstr ""

msgctxt "#30641"
Expand Down
Loading

0 comments on commit 209fc0a

Please sign in to comment.