mirror of
https://github.com/LibreELEC/LibreELEC.tv.git
synced 2025-07-28 13:16:41 +00:00
kodi: service addons: move sysdemd wrapper back to OnEnabled/OnDisabled
I dont remember why I forced reinstall of units / restart addons on kodi start, but it's not an issue anymore, so avoid restarting services. NOTE: it is now required to disable/enable once all OE specific service addons (tvheadend, vdr etc) once after upgrade. so dont pick this for oe-stable.
This commit is contained in:
parent
41a616e906
commit
85dee53e91
@ -1,7 +1,7 @@
|
|||||||
From 5d2b9a1d40720c8cc3306e7dab4e850271a1f00e Mon Sep 17 00:00:00 2001
|
From 6746387ee5681508c40a8d02747f9c1f3a7cdbc2 Mon Sep 17 00:00:00 2001
|
||||||
From: Stefan Saraev <stefan@saraev.ca>
|
From: Stefan Saraev <stefan@saraev.ca>
|
||||||
Date: Fri, 8 Aug 2014 18:22:44 +0300
|
Date: Fri, 8 Aug 2014 18:22:44 +0300
|
||||||
Subject: [PATCH] service addons: use a wrapper to setup systemd
|
Subject: [PATCH] use a wrapper to setup systemd services
|
||||||
|
|
||||||
---
|
---
|
||||||
xbmc/addons/Service.cpp | 12 ++++++++++++
|
xbmc/addons/Service.cpp | 12 ++++++++++++
|
||||||
@ -9,29 +9,18 @@ Subject: [PATCH] service addons: use a wrapper to setup systemd
|
|||||||
2 files changed, 15 insertions(+)
|
2 files changed, 15 insertions(+)
|
||||||
|
|
||||||
diff --git a/xbmc/addons/Service.cpp b/xbmc/addons/Service.cpp
|
diff --git a/xbmc/addons/Service.cpp b/xbmc/addons/Service.cpp
|
||||||
index c406b11..c23b18a 100644
|
index c406b11..808f498 100644
|
||||||
--- a/xbmc/addons/Service.cpp
|
--- a/xbmc/addons/Service.cpp
|
||||||
+++ b/xbmc/addons/Service.cpp
|
+++ b/xbmc/addons/Service.cpp
|
||||||
@@ -53,6 +53,9 @@ AddonPtr CService::Clone() const
|
@@ -53,6 +53,7 @@ AddonPtr CService::Clone() const
|
||||||
bool CService::Start()
|
bool CService::Start()
|
||||||
{
|
{
|
||||||
bool ret = true;
|
bool ret = true;
|
||||||
+
|
|
||||||
+ CallOEWrapper(ID(), false);
|
|
||||||
+
|
+
|
||||||
switch (m_type)
|
switch (m_type)
|
||||||
{
|
{
|
||||||
#ifdef HAS_PYTHON
|
#ifdef HAS_PYTHON
|
||||||
@@ -88,6 +91,8 @@ bool CService::Stop()
|
@@ -113,13 +114,24 @@ void CService::BuildServiceType()
|
||||||
break;
|
|
||||||
}
|
|
||||||
|
|
||||||
+ CallOEWrapper(ID(), true);
|
|
||||||
+
|
|
||||||
return ret;
|
|
||||||
}
|
|
||||||
|
|
||||||
@@ -113,6 +118,13 @@ void CService::BuildServiceType()
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -44,7 +33,18 @@ index c406b11..c23b18a 100644
|
|||||||
+
|
+
|
||||||
void CService::OnDisabled()
|
void CService::OnDisabled()
|
||||||
{
|
{
|
||||||
|
+ CallOEWrapper(ID(), true);
|
||||||
|
+
|
||||||
Stop();
|
Stop();
|
||||||
|
}
|
||||||
|
|
||||||
|
void CService::OnEnabled()
|
||||||
|
{
|
||||||
|
+ CallOEWrapper(ID(), false);
|
||||||
|
+
|
||||||
|
Start();
|
||||||
|
}
|
||||||
|
|
||||||
diff --git a/xbmc/addons/Service.h b/xbmc/addons/Service.h
|
diff --git a/xbmc/addons/Service.h b/xbmc/addons/Service.h
|
||||||
index 98ec8b6..36e4109 100644
|
index 98ec8b6..36e4109 100644
|
||||||
--- a/xbmc/addons/Service.h
|
--- a/xbmc/addons/Service.h
|
||||||
@ -60,5 +60,5 @@ index 98ec8b6..36e4109 100644
|
|||||||
virtual void OnEnabled();
|
virtual void OnEnabled();
|
||||||
virtual bool OnPreInstall();
|
virtual bool OnPreInstall();
|
||||||
--
|
--
|
||||||
1.9.1
|
2.1.0
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user