Skip to content

Commit

Permalink
Merge pull request #455 from AlwinEsch/interface-change
Browse files Browse the repository at this point in the history
[Matrix] change to new C++ PVR interface way
  • Loading branch information
AlwinEsch authored Jun 13, 2020
2 parents fe692ba + c13ca14 commit 86e47fb
Show file tree
Hide file tree
Showing 34 changed files with 1,492 additions and 1,567 deletions.
88 changes: 88 additions & 0 deletions .clang-format
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
---
# BasedOnStyle: LLVM
AccessModifierOffset: -2
AlignAfterOpenBracket: Align
AlignConsecutiveAssignments: false
AlignConsecutiveDeclarations: false
AlignEscapedNewlines: DontAlign
AlignOperands: true
AlignTrailingComments: false
AllowAllParametersOfDeclarationOnNextLine: true
AllowShortBlocksOnASingleLine: false
AllowShortCaseLabelsOnASingleLine: false
AllowShortFunctionsOnASingleLine: InlineOnly
AllowShortIfStatementsOnASingleLine: false
AllowShortLoopsOnASingleLine: false
AlwaysBreakAfterDefinitionReturnType: None
AlwaysBreakAfterReturnType: None
AlwaysBreakBeforeMultilineStrings: false
AlwaysBreakTemplateDeclarations: true
BinPackArguments: true
BinPackParameters: false
BreakBeforeBinaryOperators: None
BreakBeforeBraces: Allman
BreakBeforeTernaryOperators: true
BreakConstructorInitializersBeforeComma: false
BreakConstructorInitializers: BeforeColon
BreakAfterJavaFieldAnnotations: false
BreakStringLiterals: true
ColumnLimit: 100
CommentPragmas: '^ IWYU pragma:'
ConstructorInitializerAllOnOneLineOrOnePerLine: true
ConstructorInitializerIndentWidth: 2
ContinuationIndentWidth: 4
Cpp11BracedListStyle: true
DerivePointerAlignment: false
DisableFormat: false
ExperimentalAutoDetectBinPacking: false
ForEachMacros: [ foreach, Q_FOREACH, BOOST_FOREACH ]
IncludeBlocks: Regroup
IncludeCategories:
- Regex: '^<[a-z0-9_]+>$'
Priority: 3
- Regex: '^<(assert|complex|ctype|errno|fenv|float|inttypes|iso646|limits|locale|math|setjmp|signal|stdalign|stdarg|stdatomic|stdbool|stddef|stdint|stdio|stdlib|stdnoreturn|string|tgmath|threads|time|uchar|wchar|wctype)\.h>$'
Priority: 3
- Regex: '^<'
Priority: 3
- Regex: '^["<](kodi|p8-platform)\/.*\.h[">]$'
Priority: 2
- Regex: '.*'
Priority: 1
IncludeIsMainRegex: '$'
IndentCaseLabels: true
IndentWidth: 2
IndentWrappedFunctionNames: false
JavaScriptQuotes: Leave
JavaScriptWrapImports: true
KeepEmptyLinesAtTheStartOfBlocks: true
MacroBlockBegin: ''
MacroBlockEnd: ''
MaxEmptyLinesToKeep: 2
NamespaceIndentation: None
ObjCBlockIndentWidth: 2
ObjCSpaceAfterProperty: false
ObjCSpaceBeforeProtocolList: true
PenaltyBreakBeforeFirstCallParameter: 19
PenaltyBreakComment: 300
PenaltyBreakFirstLessLess: 120
PenaltyBreakString: 1000
PenaltyExcessCharacter: 1000000
PenaltyReturnTypeOnItsOwnLine: 60000
PointerAlignment: Left
ReflowComments: false
SortIncludes: true
SpaceAfterCStyleCast: false
SpaceAfterTemplateKeyword: false
SpaceBeforeAssignmentOperators: true
SpaceBeforeParens: ControlStatements
SpaceInEmptyParentheses: false
SpacesBeforeTrailingComments: 1
SpacesInAngles: false
SpacesInContainerLiterals: true
SpacesInCStyleCastParentheses: false
SpacesInParentheses: false
SpacesInSquareBrackets: false
Standard: Cpp11
TabWidth: 8
UseTab: Never
...
17 changes: 7 additions & 10 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,9 @@ include_directories(${p8-platform_INCLUDE_DIRS}
${KODI_INCLUDE_DIR}/.. # Hack way with "/..", need bigger Kodi cmake rework to match right include ways
${PROJECT_SOURCE_DIR}/lib)

add_definitions(-DUSE_DEMUX)

# Sources and headers
set(HTS_SOURCES src/client.h
src/client.cpp
set(HTS_SOURCES src/addon.h
src/addon.cpp
src/Tvheadend.cpp
src/Tvheadend.h)

Expand All @@ -30,14 +28,14 @@ set(HTS_SOURCES_TVHEADEND
src/tvheadend/HTSPVFS.h
src/tvheadend/HTSPVFS.cpp
src/tvheadend/IHTSPConnectionListener.h
src/tvheadend/IHTSPDemuxPacketHandler.h
src/tvheadend/Profile.h
src/tvheadend/Settings.cpp
src/tvheadend/Settings.h
src/tvheadend/Subscription.cpp
src/tvheadend/Subscription.h
src/tvheadend/TimeRecordings.cpp
src/tvheadend/TimeRecordings.h
src/tvheadend/xbmc_codec_descriptor.hpp)
src/tvheadend/TimeRecordings.h)

set(HTS_SOURCES_TVHEADEND_ENTITY
src/tvheadend/entity/AutoRecording.h
Expand Down Expand Up @@ -68,26 +66,25 @@ set(HTS_SOURCES_TVHEADEND_UTILITIES
src/tvheadend/utilities/Utilities.h
src/tvheadend/utilities/Logger.h
src/tvheadend/utilities/Logger.cpp
src/tvheadend/utilities/LocalizedString.h
src/tvheadend/utilities/LifetimeMapper.h
src/tvheadend/utilities/AsyncState.cpp
src/tvheadend/utilities/AsyncState.h)

source_group("Source Files" FILES ${HTS_SOURCES})
source_group("Source Files\\tvheadend" FILES ${HTS_SOURCES_TVHEADEND})
source_group("Source Files\\tvheadend\\entity" FILES ${HTS_SOURCES_TVHEADEND_ENTITY})
source_group("Source Files\\tvheadend\\status" FILES ${HTS_SOURCES_TVHEADEND_STATUS})
source_group("Source Files\\tvheadend\\utilities" FILES ${HTS_SOURCES_TVHEADEND_UTILITIES})

# Resource files
set(HTS_RESOURCES
set(HTS_RESOURCES
README.md
pvr.hts/addon.xml
pvr.hts/changelog.txt
pvr.hts/icon.png
pvr.hts/resources/settings.xml
pvr.hts/resources/language/resource.language.en_gb/strings.po)

source_group("Resource Files" FILES ${HTS_RESOURCES})

# Combine the file lists
Expand Down
4 changes: 2 additions & 2 deletions pvr.hts/addon.xml.in
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
<?xml version="1.0" encoding="UTF-8"?>
<addon
id="pvr.hts"
version="6.1.1"
version="7.0.0"
name="Tvheadend HTSP Client"
provider-name="Adam Sutton, Sam Stenvall, Lars Op den Kamp, Kai Sommerfeld">
<requires>@ADDON_DEPENDS@</requires>
<extension
point="xbmc.pvrclient"
point="kodi.pvrclient"
library_@PLATFORM@="@LIBRARY_FILENAME@"/>
<extension point="xbmc.addon.metadata">
<summary lang="af_ZA">Kodi se voorprogram vir Tvheadend</summary>
Expand Down
6 changes: 6 additions & 0 deletions pvr.hts/changelog.txt
Original file line number Diff line number Diff line change
@@ -1,3 +1,9 @@
7.0.0
- Update PVR API 7.0.0
- Rework addon to support new API interface
- Code cleanup to match a clang format
- Change settings.xml to new Kodi format

6.1.1
- fix disconnect on sleep

Expand Down
Loading

0 comments on commit 86e47fb

Please sign in to comment.