我刚刚更新了我的Parse和Facebook SDK(分别为1.7.1和4.0) - 两者都是我可能添加的工作的绝对痛苦!
但是,当我尝试使用Facebook登录时,我现在收到209错误.
这是我的代码示例:
- (void)loginWithFacebook:(HMSuccessBlock)completion{
NSArray *permissionsArray = @[@"user_about_me",@"user_location",@"user_friends",@"user_relationships"];
// Login PFUser using Facebook
[PFFacebookUtils logInInBackgroundWithReadPermissions:permissionsArray block:^(PFUser *user, NSError *error) {
if (!user) {
NSLog(@"Uh oh. The user cancelled the Facebook login.");
UIAlertView *alert = [[UIAlertView alloc] initWithTitle:@"Log In Error"
message:error.localizedDescription
delegate:nil
cancelButtonTitle:nil
otherButtonTitles:@"Dismiss", nil];
[alert show];
completion(NO, error);
} else if (user.isNew) {
NSLog(@"User signed up and logged in through Facebook!");
if (completion) {
completion(YES, nil);
}
} else {
NSLog(@"User logged in through Facebook!");
completion(YES, …Run Code Online (Sandbox Code Playgroud) 不管有谁能帮助我,我想在我的IOS项目上设置Google Analytics.我只需要一个非常简单的实现来显示加载视图的次数.我按照谷歌文档(https://developers.google.com/analytics/devguides/collection/ios/v3/),但我的仪表板中没有更新任何内容
我有一个属性设置,没有报告用户
我的appdelegate如下
#import <UIKit/UIKit.h>
#import "GAI.h"
@interface AppDelegate : UIResponder <UIApplicationDelegate>
@property (strong, nonatomic) UIWindow *window;
@property(nonatomic, strong) id<GAITracker> tracker;
@end
Run Code Online (Sandbox Code Playgroud)
我的.m包含 - (BOOL)应用程序:(UIApplication*)application didFinishLaunchingWithOptions:(NSDictionary*)launchOptions {
[GAI sharedInstance].trackUncaughtExceptions = YES;
// Optional: set Google Analytics dispatch interval to e.g. 20 seconds.
[GAI sharedInstance].dispatchInterval = 20;
// Optional: set Logger to VERBOSE for debug information.
[[[GAI sharedInstance] logger] setLogLevel:kGAILogLevelVerbose];
// Initialize tracker. which i have set up at the top of my .mn
self.tracker = [[GAI sharedInstance] …Run Code Online (Sandbox Code Playgroud) 嘿,我想知道是否有人可以指出我正确的方向。
我正在构建一个 Mac 音频应用程序,我需要执行以下操作
到目前为止,我已经研究过使用以下内容:
AudioKit
这个框架看起来很棒,并且有我想做的大部分事情的示例应用程序,但是它似乎只接受 Mac 在设置中选择的音频输入。这对我来说是不可能的,因为我希望用户能够在应用程序中进行选择(就像 GarageBand 或 Neural Dsp 插件一样)
使用AudioEngine我可以获得可用的输入设备,但我发现的所有内容都表明它们在应用程序中不可更改 - 这是显示它们的代码
struct InputDevicePicker: View {
@State var device: Device
var engine: AudioEngine
var body: some View {
Picker("Input: \(device.deviceID)", selection: $device) {
ForEach(getDevices(), id: \.self) {
Text($0.name)
}
}
.pickerStyle(MenuPickerStyle())
.onChange(of: device, perform: setInputDevice)
}
func getDevices() -> [Device] {
AudioEngine.inputDevices.compactMap { $0 }
}
func setInputDevice(to device: Device) { …Run Code Online (Sandbox Code Playgroud) macos avfoundation avcapturesession avcapturedevice audiokit
我正在创建一个函数,我需要从数组中传递值,我需要添加的值之一是 jquery css 数组的一系列值
基本上我需要做以下事情
myArray = new Array();
myArray[0] = ""{'float':'left','-webkit-border-top-left-radius':'20px','-webkit-border-bottom-left-radius':'20px','-webkit-border-top-right-radius':'0px','-webkit-border-bottom-right-radius':'20px'}";"
function(){
$("#myDiv").click(function(){
$(this).css(myArray[0]):
});
}
Run Code Online (Sandbox Code Playgroud)
这不是作为更大函数的一部分的确切代码,但是我失败的方面是将数组中的字符串传递给 .css 数组,如果我只包含数组中的值,我可以这样做,但这意味着我需要向我的数组中添加我不想做的其他项目
任何帮助 - 指针将不胜感激
所以对于上下文
好的,所以我的数组
被传递到以下函数中` function uber(arg) { $card1.animate({ height:arg[0], top:arg[1] },500).css({'z-index' :card2Pos[2]});var card2Pos = new Array();
card2Pos[0]="475px";
card2Pos[1]="80px";
card2Pos[2]="1";
card2Pos[3]="500px";
card2Pos[4]="70px";
card2Pos[5]="90px";
card2Pos[6]="510px";
card2Pos[7]="9";
card2Pos[8]="{'float':'left','-webkit-border-top-left-radius':'20px','-webkit-border-bottom-left-radius':'20px','-webkit-border-top-right-radius':'0px','-webkit-border-bottom-right-radius':'20px'}";
card2Pos[9]="475px";
card2Pos[10]="80px";
card2Pos[11]="580px";
card2Pos[12]="60px";
card2Pos[13]="8";
card2Pos[14]="right";
card2Pos[15]="450px";
card2Pos[16]="90px";
card2Pos[17]="625px";
card2Pos[18]="60px";
card2Pos[19]="7";
card2Pos[20]="right";
card2Pos[21]="425px";
card2Pos[22]="100px";
card2Pos[23]="670px";
card2Pos[24]="60px";
card2Pos[25]="6";
card2Pos[26]="right";
card2Pos[27]="400px";
card2Pos[28]="110px";
card2Pos[29]="715px";
card2Pos[30]="60px";
card2Pos[31]="5";
card2Pos[32]="right";
card2Pos[33]="375px";
card2Pos[34]="120px";
card2Pos[35]="760px";
card2Pos[36]="60px";
card2Pos[37]="4";
card2Pos[38]="right";
card2Pos[39]="350px"; …
我正在尝试实现基本的"Hello world"应用程序而在我的网站上收到错误:
<div id="map"></div>
<script type="text/javascript" src="http://maps.google.com/maps/api/js?sensor=true"></script>
$(document).ready(function () {
map = new google.maps.Map(document.getElementById("map"), myOptions);
});
Run Code Online (Sandbox Code Playgroud)
我得到的错误是:
'未捕获的ReferenceError:未定义谷歌'
我该如何解决这个问题?
ios ×2
jquery ×2
arrays ×1
audiokit ×1
avfoundation ×1
css ×1
facebook ×1
google-maps ×1
iphone ×1
javascript ×1
macos ×1
objective-c ×1