Skip to content
This repository was archived by the owner on Dec 13, 2023. It is now read-only.

Commit 80b0564

Browse files
authored
Merge pull request #5 from Orange-OpenSource/fix-warnings
Fix warnings
2 parents e1d3339 + 03f7171 commit 80b0564

File tree

5 files changed

+25
-29
lines changed

5 files changed

+25
-29
lines changed

Example/OCast-ObjC/Controllers/OBJCMainVC.m

Lines changed: 19 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -128,12 +128,12 @@ - (void)deviceDidDisconnectWithModule:(enum DriverModule)module_ withError:(NSEr
128128
NSLog(@"-> Driver is disconnected.");
129129

130130
dispatch_async(dispatch_get_main_queue(), ^{
131-
_webAppStatus.text = @"disconnected";
132-
[_stickIcon setEnabled:NO];
133-
[_stickIcon setTintColor: [UIColor blackColor]];
134-
_positionLabel.text = @"";
135-
_durationLabel.text = @"";
136-
_playerState.text = @"idle";
131+
self.webAppStatus.text = @"disconnected";
132+
[self.stickIcon setEnabled:NO];
133+
[self.stickIcon setTintColor: [UIColor blackColor]];
134+
self.positionLabel.text = @"";
135+
self.durationLabel.text = @"";
136+
self.playerState.text = @"idle";
137137
});
138138

139139
devices = deviceDiscovery.devices;
@@ -212,8 +212,8 @@ - (void)startWebApp {
212212
NSLog(@"-> WebApp started !");
213213

214214
dispatch_async(dispatch_get_main_queue(), ^{
215-
_webAppStatus.text = @"connected";
216-
[_stickIcon setTintColor: [UIColor orangeColor]];
215+
self.webAppStatus.text = @"connected";
216+
[self.stickIcon setTintColor: [UIColor orangeColor]];
217217
});
218218
};
219219

@@ -230,12 +230,12 @@ - (IBAction)onStopWebApp:(id)sender {
230230

231231

232232
dispatch_async(dispatch_get_main_queue(), ^{
233-
_webAppStatus.text = @"disconnected";
233+
self.webAppStatus.text = @"disconnected";
234234

235-
[_stickIcon setTintColor: [UIColor blackColor]];
235+
[self.stickIcon setTintColor: [UIColor blackColor]];
236236

237237
if ([devices count] == 0) {
238-
[_stickIcon setEnabled:NO];
238+
[self.stickIcon setEnabled:NO];
239239
}
240240

241241
if ([deviceDiscovery start] == NO) {
@@ -315,7 +315,7 @@ -(void)onMessageWithData:(NSDictionary *)data {
315315
NSLog(@"-> Got custom response : %@", data);
316316

317317
dispatch_async(dispatch_get_main_queue(), ^{
318-
_customResponseLabel.text = data.description;
318+
self.customResponseLabel.text = data.description;
319319
});
320320
}
321321

@@ -333,23 +333,23 @@ - (void)didReceiveEventWithPlaybackStatus:(PlaybackStatus * _Nonnull)playbackSta
333333
NSLog(@"-> Got onPlaybackStatus: Mute = %@", playbackStatus.mute ? @"yes":@"no");
334334

335335
dispatch_async(dispatch_get_main_queue(), ^{
336-
_positionLabel.text = [NSString stringWithFormat:@"%f", playbackStatus.position];
337-
_durationLabel.text = [NSString stringWithFormat:@"%f", playbackStatus.duration];
336+
self.positionLabel.text = [NSString stringWithFormat:@"%f", playbackStatus.position];
337+
self.durationLabel.text = [NSString stringWithFormat:@"%f", playbackStatus.duration];
338338
switch (playbackStatus.state) {
339339
case PlayerStateIdle:
340-
_playerState.text = @"idle";
340+
self.playerState.text = @"idle";
341341
break;
342342
case PlayerStatePaused:
343-
_playerState.text = @"paused";
343+
self.playerState.text = @"paused";
344344
break;
345345
case PlayerStatePlaying:
346-
_playerState.text = @"playing";
346+
self.playerState.text = @"playing";
347347
break;
348348
case PlayerStateBuffering:
349-
_playerState.text = @"buffering";
349+
self.playerState.text = @"buffering";
350350
break;
351351
case PlayerStateUnknown:
352-
_playerState.text = @"unknown";
352+
self.playerState.text = @"unknown";
353353
break;
354354
default:
355355
break;

Example/OCast-Swift/Base.lproj/Main.storyboard

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -545,7 +545,7 @@
545545
</constraints>
546546
</view>
547547
<navigationItem key="navigationItem" id="gqE-8O-E8g">
548-
<barButtonItem key="rightBarButtonItem" image="playtoNotConnected" style="plain" id="uqd-4S-7xj">
548+
<barButtonItem key="rightBarButtonItem" image="playtoNotConnected" id="uqd-4S-7xj">
549549
<color key="tintColor" red="0.0" green="0.0" blue="0.0" alpha="1" colorSpace="custom" customColorSpace="sRGB"/>
550550
</barButtonItem>
551551
</navigationItem>

OCast/Classes/Core/Device/DeviceDiscovery.swift

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -117,13 +117,11 @@ import CocoaAsyncSocket
117117
}
118118

119119
/**
120-
Initializes a new deviceDiscoevry class.
120+
Initializes a new deviceDiscovery class.
121121
- Parameters:
122-
- sender: module that will receive further notifications
123122
- searchTargets: list of device targets to search for
124123
- policy: `Reliability` level for discovery process
125124
*/
126-
127125
@objc public init(forTargets searchTargets: Array<String>, withPolicy policy: DeviceDiscovery.Reliability) {
128126
mSearchIdx = 0
129127
self.mSearchTargets = searchTargets
@@ -145,9 +143,8 @@ import CocoaAsyncSocket
145143
}
146144

147145
/**
148-
Initializes a new deviceDiscoevry class. The `Reliability` level is set to `.high` by default (a MSEARCH is sent every 3s. If no anwser after 6s, the device is considered as lost).
146+
Initializes a new deviceDiscovery class. The `Reliability` level is set to `.high` by default (a MSEARCH is sent every 3s. If no anwser after 6s, the device is considered as lost).
149147
- Parameters:
150-
- sender: module that will receive further notifications
151148
- searchTargets: List of device targets to search for
152149
*/
153150
public convenience init(forTargets searchTargets: Array<String>) {

OCast/Classes/Core/Device/DeviceManager.swift

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,6 @@ import Foundation
4949
Initializes a new DeviceManager.
5050

5151
- Parameters:
52-
- sender: module that will receive further notifications
5352
- device: the device to be managed
5453
- certificateInfo: Optional. An array of certificates to establish secured connections to the device.
5554
*/

OCast/Classes/Core/Models/Public.swift

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -145,9 +145,9 @@ public struct DataMapper {
145145
/// Initializer
146146
///
147147
/// - Parameters:
148-
/// - serverRootCACert: The root server certificate (DER format) used for SSL one-way (can be nil if the serverCACert includes the root certificate)
149-
/// - serverCACert: The server certificate (DER format) used for SSL one-way
150-
/// - clientCert: The client certificate (DER format) used for SSL two-way
148+
/// - serverRootCACertificate: The root server certificate (DER format) used for SSL one-way (can be nil if the serverCACert includes the root certificate)
149+
/// - serverCACertificate: The server certificate (DER format) used for SSL one-way
150+
/// - clientCertificate: The client certificate (DER format) used for SSL two-way
151151
/// - password: The password used for SSL two way
152152
public init(serverRootCACertificate: Data?, serverCACertificate: Data?, clientCertificate: Data?, password: String?) {
153153
self.serverRootCACertificate = serverRootCACertificate

0 commit comments

Comments
 (0)