Skip to content

Commit

Permalink
Zap regen
Browse files Browse the repository at this point in the history
  • Loading branch information
lazarkov committed Dec 14, 2021
1 parent e13c089 commit 2d1ca79
Show file tree
Hide file tree
Showing 81 changed files with 2,759 additions and 8,731 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,13 +9,13 @@
import chip.platform.NsdManagerServiceResolver;
import chip.platform.PreferencesConfigurationManager;
import chip.platform.PreferencesKeyValueStoreManager;
import com.tcl.chip.tvapp.ChannelManagerStub;
import com.tcl.chip.tvapp.ContentLaunchManagerStub;
import com.tcl.chip.tvapp.KeypadInputManagerStub;
import com.tcl.chip.tvapp.LowPowerManagerStub;
import com.tcl.chip.tvapp.MediaInputManagerStub;
import com.tcl.chip.tvapp.MediaPlaybackManagerStub;
import com.tcl.chip.tvapp.TvApp;
import com.tcl.chip.tvapp.ChannelManagerStub;
import com.tcl.chip.tvapp.WakeOnLanManagerStub;

public class MatterServant {
Expand Down
12 changes: 6 additions & 6 deletions examples/tv-app/android/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -38,6 +38,8 @@ shared_library("jni") {
"include/endpoint-configuration/EndpointConfigurationStorage.h",
"include/target-navigator/TargetNavigatorManager.cpp",
"include/target-navigator/TargetNavigatorManager.h",
"java/ChannelManager.cpp",
"java/ChannelManager.h",
"java/ContentLauncherManager.cpp",
"java/ContentLauncherManager.h",
"java/KeypadInputManager.cpp",
Expand All @@ -49,8 +51,6 @@ shared_library("jni") {
"java/MediaPlaybackManager.cpp",
"java/MediaPlaybackManager.h",
"java/TVApp-JNI.cpp",
"java/ChannelManager.cpp",
"java/ChannelManager.h",
"java/WakeOnLanManager.cpp",
"java/WakeOnLanManager.h",
]
Expand Down Expand Up @@ -83,6 +83,10 @@ android_library("java") {
]

sources = [
"java/src/com/tcl/chip/tvapp/ChannelInfo.java",
"java/src/com/tcl/chip/tvapp/ChannelLineupInfo.java",
"java/src/com/tcl/chip/tvapp/ChannelManager.java",
"java/src/com/tcl/chip/tvapp/ChannelManagerStub.java",
"java/src/com/tcl/chip/tvapp/ContentLaunchBrandingInformation.java",
"java/src/com/tcl/chip/tvapp/ContentLaunchManager.java",
"java/src/com/tcl/chip/tvapp/ContentLaunchManagerStub.java",
Expand All @@ -98,10 +102,6 @@ android_library("java") {
"java/src/com/tcl/chip/tvapp/MediaPlaybackManager.java",
"java/src/com/tcl/chip/tvapp/MediaPlaybackManagerStub.java",
"java/src/com/tcl/chip/tvapp/TvApp.java",
"java/src/com/tcl/chip/tvapp/ChannelInfo.java",
"java/src/com/tcl/chip/tvapp/ChannelLineupInfo.java",
"java/src/com/tcl/chip/tvapp/ChannelManager.java",
"java/src/com/tcl/chip/tvapp/ChannelManagerStub.java",
"java/src/com/tcl/chip/tvapp/WakeOnLanManager.java",
"java/src/com/tcl/chip/tvapp/WakeOnLanManagerStub.java",
]
Expand Down
7 changes: 3 additions & 4 deletions examples/tv-app/android/java/ChannelManager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -127,8 +127,7 @@ void ChannelManager::InitializeWithObjects(jobject managerObject)
env->ExceptionClear();
}

mChangeChannelMethod =
env->GetMethodID(managerClass, "changeChannel", "(Ljava/lang/String;)Lcom/tcl/chip/tvapp/ChannelInfo;");
mChangeChannelMethod = env->GetMethodID(managerClass, "changeChannel", "(Ljava/lang/String;)Lcom/tcl/chip/tvapp/ChannelInfo;");
if (mChangeChannelMethod == nullptr)
{
ChipLogError(Zcl, "Failed to access ChannelManager 'changeChannel' method");
Expand Down Expand Up @@ -396,8 +395,8 @@ bool ChannelManager::changeChannelByNumber(uint16_t majorNumber, uint16_t minorN
jboolean ret = JNI_FALSE;
JNIEnv * env = JniReferences::GetInstance().GetEnvForCurrentThread();

ChipLogProgress(Zcl, "Received ChannelManager::ChannelClusterChangeChannelByNumber majorNumber %d, minorNumber %d",
majorNumber, minorNumber);
ChipLogProgress(Zcl, "Received ChannelManager::ChannelClusterChangeChannelByNumber majorNumber %d, minorNumber %d", majorNumber,
minorNumber);
VerifyOrExit(mChannelManagerObject != nullptr, ChipLogError(Zcl, "mChannelManagerObject null"));
VerifyOrExit(mchangeChannelByNumberMethod != nullptr, ChipLogError(Zcl, "mchangeChannelByNumberMethod null"));
VerifyOrExit(env != NULL, ChipLogError(Zcl, "env null"));
Expand Down
2 changes: 1 addition & 1 deletion examples/tv-app/android/java/ChannelManager.h
Original file line number Diff line number Diff line change
Expand Up @@ -41,7 +41,7 @@ class ChannelManager
friend ChannelManager & ChannelMgr();

static ChannelManager sInstance;
jobject mChannelManagerObject = nullptr;
jobject mChannelManagerObject = nullptr;
jmethodID mGetChannelListMethod = nullptr;
jmethodID mGetLineupMethod = nullptr;
jmethodID mGetCurrentChannelMethod = nullptr;
Expand Down
2 changes: 1 addition & 1 deletion examples/tv-app/android/java/TVApp-JNI.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,12 @@
*
*/

#include "ChannelManager.h"
#include "ContentLauncherManager.h"
#include "KeypadInputManager.h"
#include "LowPowerManager.h"
#include "MediaInputManager.h"
#include "MediaPlaybackManager.h"
#include "ChannelManager.h"
#include "WakeOnLanManager.h"
#include <app/server/java/AndroidAppServerWrapper.h>
#include <jni.h>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,8 @@ public class ChannelManagerStub implements ChannelManager {

@Override
public ChannelInfo[] getChannelList() {
ChannelInfo ChannelInfo1 =
new ChannelInfo(1, 1, "HDMI1", "callSign1", "affiliateCallSign1");
ChannelInfo ChannelInfo2 =
new ChannelInfo(2, 2, "HDMI2", "callSign2", "affiliateCallSign2");
ChannelInfo ChannelInfo1 = new ChannelInfo(1, 1, "HDMI1", "callSign1", "affiliateCallSign1");
ChannelInfo ChannelInfo2 = new ChannelInfo(2, 2, "HDMI2", "callSign2", "affiliateCallSign2");
Log.d(TAG, "getChannelList");
return new ChannelInfo[] {ChannelInfo1, ChannelInfo2};
}
Expand Down
4 changes: 2 additions & 2 deletions examples/tv-app/linux/BUILD.gn
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,8 @@ executable("chip-tv-app") {
"include/application-launcher/ApplicationLauncherManager.h",
"include/audio-output/AudioOutputManager.cpp",
"include/audio-output/AudioOutputManager.h",
"include/channel/ChannelManager.cpp",
"include/channel/ChannelManager.h",
"include/cluster-change-attribute.cpp",
"include/cluster-init.cpp",
"include/content-launcher/ContentLauncherManager.cpp",
Expand All @@ -50,8 +52,6 @@ executable("chip-tv-app") {
"include/media-playback/MediaPlaybackManager.h",
"include/target-navigator/TargetNavigatorManager.cpp",
"include/target-navigator/TargetNavigatorManager.h",
"include/channel/ChannelManager.cpp",
"include/channel/ChannelManager.h",
"include/wake-on-lan/WakeOnLanManager.cpp",
"include/wake-on-lan/WakeOnLanManager.h",
"main.cpp",
Expand Down
5 changes: 2 additions & 3 deletions examples/tv-app/linux/include/cluster-init.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,10 @@
#include "application-basic/ApplicationBasicManager.h"
#include "application-launcher/ApplicationLauncherManager.h"
#include "audio-output/AudioOutputManager.h"
#include "channel/ChannelManager.h"
#include "content-launcher/ContentLauncherManager.h"
#include "media-input/MediaInputManager.h"
#include "target-navigator/TargetNavigatorManager.h"
#include "channel/ChannelManager.h"
#include "wake-on-lan/WakeOnLanManager.h"

#include <app-common/zap-generated/attribute-id.h>
Expand Down Expand Up @@ -108,8 +108,7 @@ void emberAfWakeOnLanClusterInitCallback(chip::EndpointId endpoint)

namespace {

TvAttrAccess<ChannelManager, app::Clusters::Channel::Attributes::ChannelList::TypeInfo,
&ChannelManager::proxyGetChannelList>
TvAttrAccess<ChannelManager, app::Clusters::Channel::Attributes::ChannelList::TypeInfo, &ChannelManager::proxyGetChannelList>
gChannelAttrAccess;

} // anonymous namespace
Expand Down
2 changes: 1 addition & 1 deletion examples/tv-app/linux/main.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,12 @@

#include "include/application-launcher/ApplicationLauncherManager.h"
#include "include/audio-output/AudioOutputManager.h"
#include "include/channel/ChannelManager.h"
#include "include/content-launcher/ContentLauncherManager.h"
#include "include/keypad-input/KeypadInputManager.h"
#include "include/media-input/MediaInputManager.h"
#include "include/media-playback/MediaPlaybackManager.h"
#include "include/target-navigator/TargetNavigatorManager.h"
#include "include/channel/ChannelManager.h"

#if defined(ENABLE_CHIP_SHELL)
#include <lib/shell/Engine.h>
Expand Down
9 changes: 4 additions & 5 deletions src/app/clusters/channel-server/channel-server.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ bool ChannelClusterChangeChannelByNumber(uint16_t majorNumer, uint16_t minorNumb
bool ChannelClusterSkipChannel(uint16_t count);

bool emberAfChannelClusterChangeChannelCallback(app::CommandHandler * command, const app::ConcreteCommandPath & commandPath,
const Commands::ChangeChannel::DecodableType & commandData)
const Commands::ChangeChannel::DecodableType & commandData)
{
Commands::ChangeChannelResponse::Type response;
response.channelMatch.majorNumber = 1;
Expand All @@ -71,9 +71,8 @@ bool emberAfChannelClusterChangeChannelCallback(app::CommandHandler * command, c
return true;
}

bool emberAfChannelClusterChangeChannelByNumberCallback(app::CommandHandler * command,
const app::ConcreteCommandPath & commandPath,
const Commands::ChangeChannelByNumber::DecodableType & commandData)
bool emberAfChannelClusterChangeChannelByNumberCallback(app::CommandHandler * command, const app::ConcreteCommandPath & commandPath,
const Commands::ChangeChannelByNumber::DecodableType & commandData)
{
auto & majorNumber = commandData.majorNumber;
auto & minorNumber = commandData.minorNumber;
Expand All @@ -85,7 +84,7 @@ bool emberAfChannelClusterChangeChannelByNumberCallback(app::CommandHandler * co
}

bool emberAfChannelClusterSkipChannelCallback(app::CommandHandler * command, const app::ConcreteCommandPath & commandPath,
const Commands::SkipChannel::DecodableType & commandData)
const Commands::SkipChannel::DecodableType & commandData)
{
auto & count = commandData.count;

Expand Down
18 changes: 9 additions & 9 deletions src/controller/java/zap-generated/CHIPCallbackTypes.h

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 2d1ca79

Please sign in to comment.