网站建设资讯

NEWS

网站建设资讯

flutterto,Flutter头条源码

已有iOS项目集成Flutter遇到的一些坑

1.XCode10.3,CocoaPods1.7.5, Flutter 1.8.4-pre.65(一定是master channel,不能是stable), 根据标题中的环境对应的版本自行升级,如版本高太多的话不敢保证一定会成功。

我们提供的服务有:网站制作、成都做网站、微信公众号开发、网站优化、网站认证、博兴ssl等。为近1000家企事业单位解决了网站和推广的问题。提供周到的售前咨询和贴心的售后服务,是有科学管理、有技术的博兴网站制作公司

2.参照官方文档的iOS部分很快就构建好了,于是Commod+B构建,可是马上会遇到第一个坑,如下图:

ld: warning: directory not found for option '-L/Users/wang/Library/Developer/Xcode/DerivedData/test_flutter-dbqsilcpjusqpadpdwvgsoqctumw/Build/Products/Debug-iphonesimulator/FlutterPluginRegistrant'

ld: library not found for -lFlutterPluginRegistrant

clang: error: linker command failed with exit code 1 (use -v to see invocation)

我晕这是什么鬼啊,尝试了各种方式都无效:

怀疑是没有找到静态库 lib(FlutterPluginRegistrant.a),工程目录和flutter_module目录以及flutterSDK的安装目录都搜遍了,也没有发现这个文件。。。。。。

于是怀疑是新版本的Flutter将FlutterPluginRegistrant.a移除了,根本就不存在这个文件,接下来在宿主iOS工程下的Pods目录中的『Pods-test_flutter.debug.xcconfig』文件中搜索" FlutterPluginRegistrant ",果然发现了一些线索

接下来将 带有 『 FlutterPluginRegistrant 』内容的部分全部删除( Pods-test_flutter.debug.xcconfig也如法炮制 ),修改后的配置如下:

接下来Command+B再次构建,奇迹发生了,刚才的错误消失了,继续往下走,

参照官方文档将 Appdelegate.m文件改为如下内容

Command+B走起,然而第二个坑来了,

Undefined symbols for architecture x86_64:

"_OBJC_CLASS_$_GeneratedPluginRegistrant", referenced from:

  objc-class-ref in AppDelegate.o

ld: symbol(s) not found for architecture x86_64

clang: error: linker command failed with exit code 1 (use -v to see invocation)

彻底晕倒,这又是什么鬼。。。自习一看才发试一个经典错误,原来是编译期的符号表$_GeneratedPluginRegistrant在链接期间找不到,由于GeneratedPluginRegistrant是在FlutterPluginRegistrant中定义的,这更加说明了FlutterPluginRegistrant.a根本不存在,于是接下去到刚才用命令"flutter create -t module --org com.example flutter_module"构建的 flutter_module 目录中去搜索文件GeneratedPluginRegistrant(mac系统下用finder搜索小伙伴们一定都会了),果然有所收获,在../flutter_module/.ios/Flutter/FlutterPluginRegistrant/Classes/目录下发现了两个文件GeneratedPluginRegistrant.h和GeneratedPluginRegistrant.m,这下就好办了,在宿主工程中把这两个文件添加进来,方式任意,可以reference也可以copy过来。

二话不说马上Command+B构建工程,大功告成!!可以来支烟庆祝一下了!

希望此文可以帮助迷茫中的你走出困境,现在网上关于这个错误的解决方案少之甚少,如果看到这里,此时你的问题已经得到解决了!!

找英语身体习语,谚语~

Water taro, autumn back in August, September 9 down the wind, little Spring in October, November frost or snow fall, winter and again in December to freeze.

3, Spring accounted for the winter on the 10th.

4, the first month flowers, February willow, March frozen scaffold.

5, 28 chaotic dressing, 39 grass-sa wear; in March to wear three samples in April wearing a mosquito net. --- Refers to changeable spring weather.

6, 28 a good sail.

7, spring chill rain that splashed, dry cold winter crying.

8, spring kid face, day to three changes.

9, Spring 18 rice difficult.

10, March in March, a day peeling, on the 3rd covers it.

11, in March and a half, was not to be cold enough to 100 Tagishi.

12, April eighth day Prince urine.

13, May take the Hill

14, May fifth day of dragon boat in water, May 13 knife off the water.

15, May Day is not eating rice dumplings, breaking kh Gan Qiu Fang.

16, June no wind Taiwan, there are access roads to the rain.

17, June Shijiu San plate new.

18, in June without good north.

19, June day, in July fire, stone will be baking cakes.

20, Liu Qiyue afternoon westerly winds had turned into tigers.

21, Northwest Yula Do not be too Tagishi.

22, Northwest rain, and even feeding off the next three.

23, June Liqiu tight Yo, July Liqiu oil after the autumn.

24, July Thick typhoons.

25, no panic in July and a half ghost, only to panic in July and a half of water.

26, in July and a half back to half of the autumn.

27, early in August the rain closed the door.

28, August Zhan, no one knows.

29, August 15, latch off households.

30, autumn and north-west, half close the eyes fertile.

31, burst burst of cold autumn.

32, three days the wind, frost on the 3rd, three days Yan daylight.

33, October rebound.

34, no winter rain for three days.

35, December southerly current report.

36, (December) to see the top junior high, the next to see 18.

37, no Jingzhe first ear really Lei, Sishijiuri Ukraine.

38, Vernal Equinox beans Tsai-shen.

39, Qingming Guyu, cold death of the mother tiger.

40, Lixia Xiao-Man, Tam cave are full.

41, summer solstice is not Do not be too hot, the winter solstice is not too cold not to be.

42, Liqiu Chushu, hot dead rats.

43, after a Chushu night, cold hot during the day.

44, Bailu Taiwan, no one knows.

45, beginning of winter rain may rot in winter and eat wood to make the empty rice.

46, dry winter solstice, Dan-year pocket; Dan Winter Solstice, dry years of pocket.

47, Dahan Osamu, no inner cold.

Swallows flying dragonfly rain precursors, smuggled a small quantity, fish, and water to ventilate abuse, heavy rain to come at once.

Animals of the rain forecast rain precursor Pellet groups of mosquitoes, rain ants appear in groups, cat wash

Frog call and a low Raindance will swallow the frog under the call and a low-flying swallows and so is the rain of the precursor

Flying cockroaches, there are showers cockroaches strong sensitivity to climate change, if at night to see flying cockroaches, indicating a change in the weather, there will be rain.

Spider webs, Jiuyu must be clear for a long time because, under the rain, spider webs can not be predatory, If you see a spider crawl out of webs to illustrate the weather soon turned sunny.

A Choice of a cold, autumn 10 games to put on cotton.

Morning rain that day, sunny, rainy night to dawn.

Rain just before dawn, the sun puddles.

Warm south wind, north wind cold, wind and humid westerly dry.

Jiuyu cold wind swept clean, fine set and reliable.

Sky flying cloud, rain and snow the next stop.

Dark clouds covered the sky, heavy rain faster.

Bright side there is rain, no rain on top of light.

Magpie branches called, to go out day clean.

Mosquito gets the blame, the weather should be bad.

River floating moss, complete with heavy rains come.

Earthworms on the road to climb, rain tangled, mole cricket singing, weather Qinghe

Snake aisle, rain's trillion, toad cockroaches, heavy rain is approaching.

Hair and the sound of a wind.

Stella rise overturned Oh, rain imminent; horses mouth overturned, heavy rain in the former.

Wind is the flow of the atmosphere, the atmosphere is what we commonly known as air. The wind has come from the north, there are come from the South, but also come from another direction. Because all aspects of the geographical attributes are inconsistent, so the wind has its different origin and diverse features. There is cold, there are hot; a dry wind, there are wet wind. Desert blowing in the wind, laden with sand; the surface to the wind, they contain more water vapor. Therefore, we in different wind inside, there is a different feeling, you can see the sky in different scenes. Further, if the two meet in a different style, they can easily conflict, when you can see the phenomenon of sudden change in weather.

Wind is the most likely aware of the phenomenon, so a lot of proverbs on the wind.

* Four Seasons wind and rain mother. (Hunan)

* Dongfeng is fine, no less than have to overcast. (Hubei Zaoyang)

The northern temperate regions and its - is at about 30 ° N where - the rain, brought about mainly due to cyclone. Cyclone action, always from west to east, in front of it thrived for a north-easterly or southeasterly winds. Therefore, Cyclone will go to when the easterly wind will of. Therefore, wind can be seen as a harbinger of future cyclones. Because the cyclone is a storm, the rain is the main factor temperate regions, so we can see that the wind is easterly, so I knew it was a harbinger of rainy days.

* Dongfeng Four Seasons eyes, I'm afraid the sound from wind. (Jiangsu Nanjing)

* Easterly winds blew critical rain. (Shanghai)

* Dongfeng emergency, maintenance and bamboo hat. (Hubei)

* Dongfeng emergency, maintenance and hats, since winds and clouds, the more anxious will rain. ( "Tian Five Elements" theory of wind)

Clouds down the mountain, to quit.

Twisted cloud cloud, rain Lin Lin.

Biotite Jiejia not overcast on the next.

Low clouds to rain, cloud height became fine.

Bright sky light up, the river rose Yi Zhang.

Red Cloud dark cloud, there must be big rain.

Sky beans Britain cloud, the ground Shaisi people.

Sunset clouds up, middle of the night listen to the rain sound.

Sunset Carmine, non-rain is the wind.

Sunset clouds away the rain after midnight.

Treadmill sky clouds, the ground rain Lin Lin.

Northwest from black clouds, thunderstorms will come.

Clouds from the Northeast, the there must be wind and rain.

Rain Hill wearing a hat, no rain Hill did not waist.

Spot scales the sky, sun valley do not turn.

Are not afraid of rain, a long time, as long as the Northwest spoke up.

Cloud east, with rain turned into the wind, cloud south, water Lian Lian, cloud to the west, Shimoji dressing.

When the rain when the sunny days and nights non-stop.

Clouds intercept the East, not the rain-wind. Chaotic sky top twist, wind and rain to not small.

North Korea has broken Ziyun, afternoon thunderstorms Pro.

2, the wind and weather proverbs

Dongfeng emergency, maintenance bamboo hat.

Hot wind, thunderstorms, strong.

Yi Qing pelting rain, slow rain did not open.

Health wind after the rain, the future is more ominous rain.

Shortly before rain there is wind and rain, rain no rain non-stop.

Non-easterly winds did not rain, do not scrape the west wind is not clear.

Third, light, electric, acoustic phenomena and weather proverbs

Stars dense, rain flooding back.

Star thin, good weather.

Star-ming, someday clear.

Stars blink, rain can not afford.

Direct flash rain, Wang flash rain.

Thunderstorm fried small, stuffy big thunderstorm.

Thunder zenith, though rain is not fierce.

Horizon thunder, heavy rain incessantly.

Xiaoshu soon as mine, so Huang reverse.

Southern flash fire door, the North flash rain provisional.

4, the biological response and the weather proverbs

Loach jumped the rain came.

Loach quiet, the weather was clear.

Frog calls, heavy rain to.

Chicken into the cage late trillion rain.

Swallows flying to rain.

Smuggled a small quantity morning and evening to the next.

Bee nest return late visit to Japan is good weather.

Water fish jump, wind and rain came.

Dragonfly flying too low, go out with enterprises.

Black dragonfly chaos, the weather should be dry.

Flutter to smoke, rain incessantly.

Tank to wear skirts, heavy rain Lin Lin.

Rain days will be damp salty things.

Pillar at the foot of tide and rain.

Cao Hui formed cakes, days of wind and rain provisional.

The water pan moss, days of the storm comes. Clouds down the mountain, to quit.

Twisted cloud cloud, rain Lin Lin.

Biotite Jiejia not overcast on the next.

Low clouds to rain, cloud height became fine.

Bright sky light up, the river rose Yi Zhang.

Red Cloud dark cloud, there must be big rain.

Sky beans Britain cloud, the ground Shaisi people.

Sunset clouds up, middle of the night listen to the rain sound.

Sunset Carmine, non-rain is the wind.

Sunset clouds away the rain after midnight.

Treadmill sky clouds, the ground rain Lin Lin.

Northwest from black clouds, thunderstorms will come.

Clouds from the Northeast, the there must be wind and rain.

Rain Hill wearing a hat, no rain Hill did not waist.

Spot scales the sky, sun valley do not turn.

Are not afraid of rain, a long time, as long as the Northwest spoke up.

Cloud east, with rain turned into the wind, cloud south, water Lian Lian, cloud to the west, Shimoji dressing.

When the rain when the sunny days and nights non-stop.

Clouds intercept the East, not the rain-wind. Chaotic sky top twist, wind and rain to not small.

North Korea has broken Ziyun, afternoon thunderstorms Pro.

2, the wind and weather proverbs

Dongfeng emergency, maintenance bamboo hat.

Hot wind, thunderstorms, strong.

Yi Qing pelting rain, slow rain did not open.

Health wind after the rain, the future is more ominous rain.

Shortly before rain there is wind and rain, rain no rain non-stop.

Non-easterly winds did not rain, do not scrape the west wind is not clear.

Third, light, electric, acoustic phenomena and weather proverbs

Stars dense, rain flooding back.

Star thin, good weather.

Star-ming, someday clear.

Stars blink, rain can not afford.

Direct flash rain, Wang flash rain.

Thunderstorm fried small, stuffy big thunderstorm.

Thunder zenith, though rain is not fierce.

Horizon thunder, heavy rain incessantly.

Xiaoshu soon as mine, so Huang reverse.

Southern flash fire door, the North flash rain provisional.

4, the biological response and the weather proverbs

Loach jumped the rain came.

Loach quiet, the weather was clear.

Frog calls, heavy rain to.

Chicken into the cage late trillion rain.

Swallows flying to rain.

Smuggled a small quantity morning and evening to the next.

Bee nest return late visit to Japan is good weather.

Water fish jump, wind and rain came.

Dragonfly flying too low, go out with enterprises.

Black dragonfly chaos, the weather should be dry.

Flutter to smoke, rain incessantly.

Tank to wear skirts, heavy rain Lin Lin.

Rain days will be damp salty things.

Pillar at the foot of tide and rain.

Cao Hui formed cakes, days of wind and rain provisional.

The water pan moss, days of the storm comes.

Clouds down the mountain, to quit.

Twisted cloud cloud, rain Lin Lin.

Biotite Jiejia not overcast on the next.

Low clouds to rain, cloud height became fine.

Bright sky light up, the river rose Yi Zhang.

Red Cloud dark cloud, there must be big rain.

Sky beans Britain cloud, the ground Shaisi people.

Sunset clouds up, middle of the night listen to the rain sound.

Sunset Carmine, non-rain is the wind.

Sunset clouds away the rain after midnight.

Treadmill sky clouds, the ground rain Lin Lin.

Northwest from black clouds, thunderstorms will come.

Clouds from the Northeast, the there must be wind and rain.

Rain Hill wearing a hat, no rain Hill did not waist.

Spot scales the sky, sun valley do not turn.

Are not afraid of rain, a long time, as long as the Northwest spoke up.

Cloud east, with rain turned into the wind, cloud south, water Lian Lian, cloud to the west, Shimoji dressing.

When the rain when the sunny days and nights non-stop.

Clouds intercept the East, not the rain-wind. Chaotic sky top twist, wind and rain to not small.

North Korea has broken Ziyun, afternoon thunderstorms Pro.

2, the wind and weather proverbs

Dongfeng emergency, maintenance bamboo hat.

Hot wind, thunderstorms, strong.

Yi Qing pelting rain, slow rain did not open.

Health wind after the rain, the future is more ominous rain.

Shortly before rain there is wind and rain, rain no rain non-stop.

Non-easterly winds did not rain, do not scrape the west wind is not clear.

Third, light, electric, acoustic phenomena and weather proverbs

Stars dense, rain flooding back.

Star thin, good weather.

Star-ming, someday clear.

Stars blink, rain can not afford.

Direct flash rain, Wang flash rain.

Thunderstorm fried small, stuffy big thunderstorm.

Thunder zenith, though rain is not fierce.

Horizon thunder, heavy rain incessantly.

Xiaoshu soon as mine, so Huang reverse.

Southern flash fire door, the North flash rain provisional.

4, the biological response and the weather proverbs

Loach jumped the rain came.

Loach quiet, the weather was clear.

Frog calls, heavy rain to.

Chicken into the cage late trillion rain.

Swallows flying to rain.

Smuggled a small quantity morning and evening to the next.

Bee nest return late visit to Japan is good weather.

Water fish jump, wind and rain came.

Dragonfly flying too low, go out with enterprises.

Black dragonfly chaos, the weather should be dry.

Flutter to smoke, rain incessantly.

Tank to wear skirts, heavy rain Lin Lin.

Rain days will be damp salty things.

Pillar at the foot of tide and rain.

Cao Hui formed cakes, days of wind and rain provisional.

The water pan moss, days of the storm comes.

flutter图片内存优化

按照给定尺寸进行图片的解码,而不是解码整个图片的尺寸,用来减少内存的占用。

官方文档:

官方说明:

Instructs Flutter to decode the image at the specified dimensions instead of at its native size.

This allows finer control of the size of the image in ImageCache and is generally used to reduce the memory footprint of ImageCache .

The decoded image may still be displayed at sizes other than the cached size provided here.

使用:

三方库: cached_network_image 限2.5.0之后版本才可用

设定最大的缓存宽度和高度 this.maxWidthDiskCache 、 this.maxHeightDiskCache

使用:

从相册选取图片,展示时使用指定尺寸宽高进行处理。

使用三方库:

使用自定义 provider 来指定所需图片的宽高:

AssetEntityImageProvider 传入宽高和图片原图 AssetEntity 数据。

provider 中 key.entity.thumbDataWithSize 方法:

进入 entity 中 thumbDataWithSize 方法:

进入 _getThumbDataWithId 方法中,

进入getThumb:

调用iOS原生的获取图片方法,

进入 getThumbWithId 方法,

原生实现获取置顶宽高缩略图方法实现:

使用 iOS 原生类 PHImageManager 的

来获取缩略图。

Flutter 项目升级报错处理

1、flutter Warning: Podfile is out of date

Warning: Podfile is out of date This can cause a mismatched version of Flutter to be embedded in your app, which may result in App Store submission rejection or crashes. If you have local Podfile edits you would like to keep, see for instructions. To regenerate the Podfile, run: rm iOS/Podfile

2、Automatically assigning platform iOS with version 8.0 on target Runner 或者Automatically assigning platform iOS with version 12.0 on target Runner because no platform was specified. Please specify a platform for this target in your Podfile

解决:只要修改ios目录下podfile 第二行 去掉#号

原因是:没有指定iOS版本。

3、 'AMapFoundation' uses the unencrypted 'http' protocol to transfer the Pod. Please be sure you're in a safe network with only trusted hosts. Otherwise, please reach out to the library author to notify them of this security issue.

类似的问题

解决方法:

登录 寻找相关最新版本更新一下。

4、[!] An error occurred while processing the post-install hook of the Podfile.

undefined method `each_child' for #Dir:0x00007f8415636e38

Did you mean? each_slice

解决办法:升级ruby

flutter怎么读

flutter的读音是[ˈflʌtər]。

表达意思:飘动,颤动;振(翼),拍打(翅膀);翩翩飞舞;(心脏等)砰砰乱跳;急赶,奔走;(心脏等)怦怦乱跳;飘动,颤动;英,非正式 小赌注;激动,不安;(心脏因激动或紧张而)快速跳动;(录音中的)颤振。

词性:通常在句中既可以作名词,也可以作动词。

例句

1、Her chiffon skirt was fluttering in the night breeze.

她的薄绸裙在晚风中飘动。

2、The paper fluttered to the floor.

纸飘落到地板上。

3、He did not even flutter his wings; he sat without stirring, and looked at Mary.

他甚至没有扇动他的翅膀;他一动不动地坐着,望着玛丽。


分享题目:flutterto,Flutter头条源码
网站URL:http://njwzjz.com/article/phjscs.html