没有编译器错误。我在运行时收到此错误。
error: package com.nguyenhoanglam.imagepicker.activity does not exist
Run Code Online (Sandbox Code Playgroud)
我在我的项目中使用了许多库。图书馆链接:
https://github.com/nguyenhoanglam/ImagePicker
改之前没有问题。
项目摇篮:
// Top-level build file where you can add configuration options common to all sub-projects/modules.
buildscript {
repositories {
google()
jcenter()
maven { url 'https://maven.google.com' }
maven { url "https://jitpack.io"}
}
dependencies {
classpath 'com.android.tools.build:gradle:3.5.4'
//classpath 'com.google.gms:google-services:1.3.0-beta1'
classpath 'com.google.gms:google-services:4.3.3'
// NOTE: Do not place your application dependencies here; they belong
// in the individual module build.gradle files
}
} …Run Code Online (Sandbox Code Playgroud) 我想了解 admob 原生广告政策。
他们在政策中说
确保空白(或背景图像)不可点击。
- 只有广告标题、URL、CTA 和非背景图像资源应该是可点击的。
- 检查您不打算放置的文本周围是否有额外的空白。
- 用于显示原生广告资源的 TextView 与其他资源相同,因此您可以使用正常的布局技术来格式化它们。
例如,您可以使用wrap_content属性值来确保您的TextView不会扩展超出显示文本所需的大小。
https://support.google.com/admob/answer/6240814?hl=zh-CN&ref_topic=7384666
我想确定哪些元素是可点击的?哪些元素不可点击?
我的想法是什么?我认为...
1:不可点击
2:可点击
3:可点击
4:可点击
5:可点击
6:不可点击-现实:这里有问题!Admob 未通过其政策中的评级,但可在其自定义 .xib 文件中单击。
只有广告标题、URL、CTA 和非背景图像资源应该是可点击的。
7:不可点击-现实:这里有问题!Admob 不会在其策略中传递正文,但可以在其自定义 .xib 文件中单击正文。
只有广告标题、URL、CTA 和非背景图像资源应该是可点击的。
8:可点击
你怎么认为?我对吗?根据 Admob 政策,评级或正文是否可点击?
请按照以下格式回答我的问题:
1: CLICKABLE or NOT CLICKABLE
2: CLICKABLE or NOT CLICKABLE
3: CLICKABLE or NOT CLICKABLE
4: CLICKABLE or NOT CLICKABLE
5: CLICKABLE or NOT CLICKABLE
6: CLICKABLE or NOT CLICKABLE
7: CLICKABLE or …Run Code Online (Sandbox Code Playgroud) 我有一个文章应用程序,我在webview中显示文章.在Android版本8.1和9.0中这个webview无法正常工作.该应用程序在文章活动中显示NOTHING.
mWebView.setVisibility(View.VISIBLE);
mWebView.getSettings().setJavaScriptEnabled(true);
mWebView.getSettings().setLoadWithOverviewMode(true);
mWebView.getSettings().setUseWideViewPort(true);
mWebView.getSettings().setMinimumFontSize(14);
String htmlContent = "<?xml version=\"1.0\" encoding=\"UTF-8\" ?>"
+ "<head>"
+ "<meta http-equiv=\"content-type\" content=\"text/html; charset=utf-8\" />"
+ "<meta name=\"viewport\" content=\"width=device-width, initial-scale=1.0\"/>"
+ "<style type=\"text/css\">body{color: #525252;} img {max-width: 100%; height: auto}</style>"
+ "</head>"
+ item.getContent() //content of item
+ "";
mWebView.loadData(htmlContent, "text/html; charset=utf-8", "UTF-8");
Run Code Online (Sandbox Code Playgroud)
结果,我该如何解决这个问题?
如您所知,Admob向发布商发送了有关app-ads.txt文件的电子邮件。在电子邮件中,Admob说
因此,如果您已经在发布日期之前发布了app-ads.txt文件,我们邀请您仔细检查它。该文件应发布在您的Android Play商店或iOS App Store列表中列出的网站的根目录中
实际上,我可以在域根文件中成功添加新的app-ads.txt文件,对于我的Google Play应用,我可以在Admob面板中看到绿色圆圈。
另一方面,对于我的iPhone应用程序,我找不到如何将网站添加到“应用程序商店列表”页面。
我将app-ads.txt文件添加到了域根目录,但是我不知道如何将该域与我的App Store应用程序关联。
如何将我的域名(URL)与我的App Store应用相关?我找不到像
网站
要么
域
在App Store Connect中。
我正在为我的游戏使用 Buildbox。我实施了自定义激励广告。问题是当奖励视频打开时游戏音乐会继续。我想在观看视频后静音和取消静音。
我知道 Java,但我不擅长 Objective-C 和 Cocos2dx。
我的AudioEngine.h类:在 libs/cocos2dx/include/audio/include/ 下
/****************************************************************************
Copyright (c) 2014-2015 Chukong Technologies Inc.
http://www.cocos2d-x.org
Permission is hereby granted, free of charge, to any person obtaining a copy
of this software and associated documentation files (the "Software"), to deal
in the Software without restriction, including without limitation the rights
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
copies of the Software, and to permit persons to whom the Software is
furnished to do …Run Code Online (Sandbox Code Playgroud) 我想在播放歌曲时进行跟踪。我尝试了网络上的不同解决方案,但他们无法解决我的问题。我实现了audioPlayerDidFinishPlaying方法,但它不起作用。我怎么知道播放歌曲是否完成?
我正在播放带有playSound功能的歌曲
播放声音 功能:
func playSound(name: String ) {
guard let url = Bundle.main.url(forResource: name, withExtension: "mp3") else {
print("url not found")
return
}
do {
/// this codes for making this app ready to takeover the device audio
try AVAudioSession.sharedInstance().setCategory(AVAudioSessionCategoryPlayback)
try AVAudioSession.sharedInstance().setActive(true)
/// change fileTypeHint according to the type of your audio file (you can omit this)
player = try AVAudioPlayer(contentsOf: url, fileTypeHint: AVFileTypeMPEGLayer3)
// no need for prepareToPlay because prepareToPlay is happen automatically when …Run Code Online (Sandbox Code Playgroud) 我试图在无状态小部件中调用一个方法,但它给出了错误。
X级:
class X extends StatelessWidget {
const X({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Column(
children: [
Divider(height: 5,),
ListTile(
title: Text('X').tr(),
leading: Container(
height: 30,
width: 30,
decoration: BoxDecoration(
color: Colors.red,
borderRadius: BorderRadius.circular(5)
),
child: Icon("x", size: 20, color: Colors.white),
),
trailing: Icon("x", size: 20,),
onTap: _openDialog(context),//This line is problematic! If I remove this line, it does not give any error.
),
],
);
}
_openDialog(context) {
return showDialog(
barrierDismissible: true,
context: context,
builder: …Run Code Online (Sandbox Code Playgroud) 当用户单击按钮时,我试图从 firebase 中删除数据。
await context线路有问题!
class SecurityOption extends StatelessWidget {//StatelessWidget
const SecurityOption({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return Column(
children: [
Divider(
height: 3,
),
ListTile(
title: Text('security').tr(),
leading: Container(
height: 30,
width: 30,
decoration: BoxDecoration(
color: Colors.red, borderRadius: BorderRadius.circular(5)),
child: Icon(Feather.lock, size: 20, color: Colors.white),
),
trailing: Icon(
Feather.chevron_right,
size: 20,
),
onTap: () => _openDeleteDialog(context),
),
],
);
}
_openDeleteDialog(context) {
return showDialog(
barrierDismissible: true,
context: context,
builder: (context) {
return AlertDialog(
title: …Run Code Online (Sandbox Code Playgroud)