+- (BOOL)shuffleEnabled
+{
+ int result = [[ITAppleEventCenter sharedCenter]
+ sendTwoTierAEWithRequestedKeyForNumber:@"pShf" fromObjectByKey:@"pPla" eventClass:@"core" eventID:@"getd" appPSN:iTunesPSN];
+ return result;
+}
+
+- (BOOL)setShuffleEnabled:(BOOL)enabled
+{
+ [[ITAppleEventCenter sharedCenter] sendAEWithSendString:[NSString stringWithFormat:@"data:long(%lu) ----:obj { form:'prop', want:type('prop'), seld:type('pShf'), from:obj { form:'prop', want:type('prop'), seld:type('pPla'), from:'null'() } }",enabled] eventClass:@"core" eventID:@"setd" appPSN:iTunesPSN];
+}
+
+- (ITMTRemotePlayerRepeatMode)repeatMode
+{
+ FourCharCode m00f;
+ int result;
+ m00f = [[ITAppleEventCenter sharedCenter]
+ sendTwoTierAEWithRequestedKeyForNumber:@"pRpt" fromObjectByKey:@"pPla" eventClass:@"core" eventID:@"getd" appPSN:iTunesPSN];
+
+ switch (m00f)
+ {
+ case 'kRp0':
+ result = ITMTRemotePlayerRepeatOff;
+ break;
+ case 'kRp1':
+ result = ITMTRemotePlayerRepeatOne;
+ break;
+ case 'kRpA':
+ result = ITMTRemotePlayerRepeatAll;
+ break;
+ }
+
+ return result;
+}
+
+- (BOOL)setRepeatMode:(ITMTRemotePlayerRepeatMode)repeatMode
+{
+ FourCharCode m00f;
+ switch (repeatMode)
+ {
+ case ITMTRemotePlayerRepeatOff:
+ m00f = 'kRp0';
+ break;
+ case ITMTRemotePlayerRepeatOne:
+ m00f = 'kRp1';
+ break;
+ case ITMTRemotePlayerRepeatAll:
+ m00f = 'kRpA';
+ break;
+ }
+
+ [[ITAppleEventCenter sharedCenter] sendAEWithSendString:[NSString stringWithFormat:@"data:long(%lu) ----:obj { form:'prop', want:type('pRpt'), seld:type('pShf'), from:obj { form:'prop', want:type('prop'), seld:type('pPla'), from:'null'() } }",m00f] eventClass:@"core" eventID:@"setd" appPSN:iTunesPSN];
+
+}
+