x

推荐测速 APP

  • 趋势分析

    掌控网站性能变化曲线,为网站速度优化提供有力的参考 [详细介绍]

  • 错误分析

    24小时监控数据的报错分析,网站在什么时间访问出错... [详细介绍]

  • 区域分析

    通过区域分析,迅速找出网站在哪些地方速度慢 [详细介绍]

  • ISP分析

    通过ISP分析,迅速找出网站在哪些运营商速度慢 [详细介绍]

  • 监测点分析

    提供监测点数据,以便反向查找问题 [详细介绍]

测速排名 今日 本周 本月

排名 域名 时间
1 WWW.YDB4888.COM 0.54s
2 WWW.SBD045.NET 0.67s
3 WWW.HG0086.COM 0.213s
4 WWW.13789UU.COM 0.807s
5 WWW.LAO512.COM 0.6s
6 WWW.0553DRF.COM 0.401s
7 WWW.07163E.COM 0.220s
8 WWW.34111.COM 0.679s
9 WWW.22ZZ8331.COM 0.268s
10 WWW.XY627.COM 0.658s

最新测速

域名 类型 时间
WWW.917905.COM get 0.94s
WWW.2875Z.COM get 1.83s
WWW.PK3588.COM get 0.294s
WWW.LG888888.COM get 0.325s
WWW.60MMM.NET get 0.264s
WWW.2127SS.COM get 0.393s
WWW.335266.COM get 0.857s
WWW.86339A.COM get 0.629s
WWW.58001B.COM get 1.188s
WWW.RD789.COM get 0.473s

 

澳门捕鱼游戏WWW.22333003.COM_太阳城AppWWW.22333003.COM

瀹惰鎸囦唬瀹跺涵浣忓畢瑁呴グ瑁呬慨鐨勭畝绉帮紝鏄寚浣忓畢绔e伐楠屾敹鍚堟牸鍚庯紝涓氫富鎴栬呬綇瀹呬娇鐢ㄤ汉锛堜互涓嬬畝绉拌淇汉锛夊浣忓畢瀹ゅ唴杩涜瑁呴グ瑁呬慨鐨勫缓绛戞椿鍔紝鍖呭惈瀹ゅ唴璁捐銆佸缓鏉愬灞呴噰璐佺‖瑁呮柦宸ャ佽蒋瑁呴厤楗扮瓑鍏ㄩ儴娴佺▼銆

渚涘簲閾炬柟闈紝瑁呬慨杩囩▼涓秹鍙婂埌鐨勪富杈呮潗鍝佺被绻佸锛屽己澶ц岀ǔ瀹氱殑渚涘簲閾炬槸纭繚浜у搧浠蜂綆璐ㄤ紭鐨勫叧閿

姝f墍璋撳叺鐔婄唺涓涓紝灏嗙唺鐔婁竴绐濓紝鍏徃鐨勮佹澘涓嶈锛岄偅涔堟槸寰堥毦鍋氬嚭鎴愮哗鐨勶紝椤圭洰涔熷緢闅句繚璇佹垚鍔

鍦ㄨ仛鍚堢悊璁轰腑锛岃仛鍚堝櫒鏈変笁涓吀鍨嬬壒鐐癸紝绗竴鏄洿鎺ヤ笌瀹㈡埛寤虹珛閾炬帴锛岀浜屾槸杈归檯鎴愭湰涓洪浂锛堟暟瀛椾骇鍝侊紝鏃犻檺澶嶅埗锛夛紝绗笁鏄殢瑙勬ā鎵╁ぇ鑾峰鎴愭湰閫愭笎闄嶄綆銆

鍚屾椂鍚勭被娓告垙涓璁$殑杩涘害鏉★紝涔熻鐢ㄦ埛鏇存湁鍔ㄥ姏鍘诲畬鎴愩

杈冨幓骞翠笂娑ㄧ害54锛咃紝浣嗕粠鍘嗗彶鏈楂樹綅锛堢暐楂樹簬20000缇庡厓锛夊凡缁忔毚璺屼簡51锛呫

var default_decoration = BoxDecoration( border: Border.all(width: 3, color: Colors.deepOrange), borderRadius: BorderRadius.all( Radius.circular(5), )); ... ... child: Container( margin: EdgeInsets.all(8), decoration: default_decoration, child: widget.child, )); 鏈鍚庣粰澶у涓涓畬鏁寸殑鏈鏂扮殑鎶鏈柟妗堢殑渚嬪瓙浠g爜: 鍏堢粯鍒舵杩庨〉锛屾晥鏋滃浘濡備笅: 浠g爜濡備笅: // 鍚姩娆㈣繋椤 import dart:async; import package:flutter/material.dart; import package:flutter/services.dart; import ui/tv_page.dart; void main => runApp(MyApp); class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { SystemChrome.setEnabledSystemUIOverlays([]); // 寮哄埗妯睆 SystemChrome.setPreferredOrientations([ DeviceOrientation.landscapeLeft, DeviceOrientation.landscapeRight ]); return MaterialApp( title: Flutter TV, debugShowCheckedModeBanner: false, theme: ThemeData( primarySwatch: Colors.blue, ), home: MyHomePage, ); } } class MyHomePage extends StatefulWidget { @override _MyHomePageState createState => _MyHomePageState; } class _MyHomePageState extends State<MyHomePage> { Timer timer; @override void initState { startTimeout; super.initState; } @override Widget build(BuildContext context) { return Scaffold( primary: true, backgroundColor: Colors.black54, body: Center( child: Text( 鑺掓灉TV, style: TextStyle( fontSize: 50, color: Colors.deepOrange, fontWeight: FontWeight.normal), ), ), ); } _toPage { Navigator.pushAndRemoveUntil( context, MaterialPageRoute(builder: (context) => TVPage), (route) => route == null, ); } //鍊掕鏃跺鐞 static const timeout = const Duration(seconds: 3); startTimeout { timer = Timer(timeout, handleTimeout); return timer; } void handleTimeout { _toPage; } @override void dispose { if (timer != null) { timer.cancel; timer = null; } super.dispose; } } 搴旂敤棣栭〉锛屾晥鏋滃浘濡備笅: 浠g爜濡備笅: // 搴旂敤棣栭〉 import dart:async; import package:flutter/material.dart; import package:flutter/services.dart; import package:flutter_tv/utils/time_utils.dart; import package:flutter_tv/widgets/tv_widget.dart; import home_page.dart; import list_page.dart; class TVPage extends StatefulWidget { @override State<StatefulWidget> createState { SystemChrome.setEnabledSystemUIOverlays([]); // 寮哄埗妯睆 SystemChrome.setPreferredOrientations( [DeviceOrientation.landscapeLeft, DeviceOrientation.landscapeRight]); return TVPageState; } } class TVPageState extends State<TVPage> with SingleTickerProviderStateMixin { TabController _tabController; Timer timer; var timeString = TimeUtils.getTime; bool init = false; FocusNode focusNodeB0 = FocusNode; FocusNode focusNodeB1 = FocusNode; @override void initState { super.initState; //initialIndex涓哄垵濮嬮変腑绗嚑涓紝length涓烘暟閲 _tabController = TabController(initialIndex: 0, length: 8, vsync: this); // 鐩戝惉 _tabController.addListener( { switch (_tabController.index) { case 0: break; case 1: break; } }); focusNodeB0.addListener( { if (focusNodeB0.hasFocus) { setState( { _tabController.animateTo(0); }); } }); focusNodeB1.addListener( { if (focusNodeB1.hasFocus) { setState( { _tabController.animateTo(1); }); } }); } @override Widget build(BuildContext context) { return Container( color: Colors.black87, padding: EdgeInsets.all(30), child: Scaffold( appBar: AppBar( backgroundColor: Colors.black87, leading: Icon( Icons.live_tv, color: Colors.deepOrange, size: 50, ), title: Text( 鑺掓灉TV, style: TextStyle( fontSize: 30, color: Colors.white, fontStyle: FontStyle.italic), ), primary: true, actions: <Widget>[ FlatButton( child: Text( $timeString, style: TextStyle(color: Colors.white), ), ), ], // 璁剧疆TabBar bottom: TabBar( controller: _tabController, indicatorColor: Colors.deepOrange, labelColor: Colors.deepOrange, unselectedLabelColor: Colors.white, tabs: <Widget>[ Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(0); }); } }, child: Text( 棣栭〉, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), requestFocus: true, ), ), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(1); }); } }, child: Text( 绮鹃, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), )), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(2); }); } }, onclick: { print(鐐瑰嚮); }, child: Text( 鍥戒骇, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), )), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(3); }); } }, child: Text( 娆х編, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), )), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(4); }); } }, child: Text( 鏃ユ极, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(5); }); } }, child: Text( 浜插瓙, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(6); }); } }, child: Text( 灏戠患, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), Tab( child: TVWidget( focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(7); }); } }, hasDecoration: false, child: Text( 鍒嗙被, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), ], ), ), body: TabBarView( controller: _tabController, children: <Widget>[ HomePage, ListPage, HomePage, ListPage, HomePage, ListPage, HomePage, ListPage, ], ), ), ); } startTimeout { timer = Timer.periodic(Duration(minutes: 1), (t) { setState( { timeString = TimeUtils.getTime; }); }); } @override void dispose { if (timer != null) { timer.cancel; timer == null; } super.dispose; } } // TAB椤甸潰涓殑鍏朵腑涓涓〉闈紝鍏朵粬绫讳技 import package:flutter/material.dart; import package:flutter/widgets.dart; import package:flutter_tv/widgets/tv_widget.dart; class HomePage extends StatefulWidget { const HomePage({ Key key, @required this.index, }) : super(key: key); final int index; @override State<StatefulWidget> createState { return HomePageState; } } class HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin { @override void initState { super.initState; } @override Widget build(BuildContext context) { return Container( color: Colors.black87, child: Row( children: <Widget>[ Flexible( child: Column( children: <Widget>[ _buildItem(0), _buildItem(1), _buildItem(2), ], ), flex: 1, ), Flexible( child: Column( children: <Widget>[ _buildImageItem(3, 2), Expanded( flex: 1, child: Row( children: <Widget>[ _buildImageItem(4, 1), _buildImageItem(5, 1), ], )), ], ), flex: 4, ), Flexible( child: Column( children: <Widget>[ _buildImageItem(6, 2), _buildImageItem(7, 1), ], ), flex: 2, ), Flexible( child: Column( children: <Widget>[ _buildImageItem(8, 2), _buildImageItem(9, 1), ], ), flex: 2, ), ], ), ); } _buildItem(int index) { return Expanded( child: TVWidget( focusChange: (hasfocus) {}, child: Container( width: MediaQuery.of(context).size.width, child: GestureDetector( child: Card( elevation: 5, margin: EdgeInsets.all(0), color: _colors.elementAt(index), child: Container( child: Column( crossAxisAlignment: CrossAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center, children: <Widget>[ _icons.elementAt(index), _title.elementAt(index), ], ), ), ), onTap: { _click(index); }, ), )), flex: 1, ); } _buildImageItem(int index, int flex) { return Expanded( child: TVWidget( child: Container( width: MediaQuery.of(context).size.width, child: GestureDetector( child: Card( elevation: 5, margin: EdgeInsets.all(0), color: _colors.elementAt(index), child: Container( child: Stack( alignment: Alignment.bottomLeft, children: <Widget>[ ClipRRect( child: Image.asset( _images.elementAt(index), fit: BoxFit.fill, width: MediaQuery.of(context).size.width, height: MediaQuery.of(context).size.height, ), borderRadius: BorderRadius.all( Radius.circular(5), ), ), Container( width: MediaQuery.of(context).size.width, child: Column( mainAxisSize: MainAxisSize.min, crossAxisAlignment: CrossAxisAlignment.start, children: <Widget>[ _title.elementAt(index), index == 3 ? _des.elementAt(index) : SizedBox( height: 0, ), ], ), color: _colors.elementAt(index).withAlpha(240), padding: EdgeInsets.all(5), ), ], ), ), ), onTap: { _click(index); }, ), ), focusChange: (hasfocus) {}, ), flex: flex, ); } void _click(int index) { switch (index) { case 0: break; case 4: // Navigator.push(context, MaterialPageRoute(builder: (context) { // return AboutPage; // })); break; } } List<Icon> _icons = [ Icon( Icons.search, size: 38, color: Colors.white, ), Icon( Icons.history, size: 38, color: Colors.white, ), Icon( Icons.event, size: 38, color: Colors.white, ), Icon( Icons.share, size: 38, color: Colors.deepPurpleAccent, ), Icon( Icons.error_outline, size: 38, color: Colors.orange, ), Icon( Icons.settings, size: 38, color: Colors.red, ) ]; List<String> _images = [ assets/htpy.jpg, assets/htpy.jpg, assets/htpy.jpg, assets/htpy.jpg, assets/agzz.jpg, assets/amypj.jpg, assets/hmjz.jpg, assets/dxflqm.jpg, assets/lifeandpi.jpg, assets/nanasqc.jpg, ]; List<Color> _colors = [ Colors.red, Colors.orange, Colors.green, Colors.red, Colors.orange, Colors.green, Colors.orange, Colors.orange, Colors.orange, Colors.orange, ]; List<Text> _title = [ Text( 鎼滅储, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鍘嗗彶, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 涓撻, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鐜お骞虫磱, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 闃跨敇姝d紶, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鍌叉參涓庡亸瑙, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 榛戠尗璀﹂暱, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 褰撳垢绂忔潵鏁查棬, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( Life Or PI, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鍝晩鍝晩绁炲幓鏉, style: TextStyle(color: Colors.white, fontSize: 18), ), ]; List<Text> _des = [ Text( 闈炲父濂界湅鐨勭數褰, style: TextStyle(color: Colors.white, fontSize: 12), ), Text( 璁剧疆瀵嗙爜閿, style: TextStyle(color: Colors.white, fontSize: 12), ), Text( 鍚愭Ы鍙嶉浣犵殑鎯虫硶, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), Text( 闈炲父濂界湅鐨勭數褰, style: TextStyle(color: Colors.white, fontSize: 12), ), Text( 鐗堟湰淇℃伅, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), Text( 绯荤粺鐩稿叧璁剧疆, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), Text( 绯荤粺鐩稿叧璁剧疆, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), ]; @override // TODO: implement wantKeepAlive bool get wantKeepAlive => true; } 灏佽鐨勬牳蹇冪被: // 灏佽鐨勬牳蹇冪劍鐐瑰鐞嗙被 import package:flutter/material.dart; import package:flutter/services.dart; import package:flutter/widgets.dart; class TVWidget extends StatefulWidget { TVWidget( {Key key, @required this.child, @required this.focusChange, @required this.onclick, @required this.decoration, @required this.hasDecoration = true, @required this.requestFocus = false}) : super(key: key); Widget child; onFocusChange focusChange; onClick onclick; bool requestFocus; BoxDecoration decoration; bool hasDecoration; @override State<StatefulWidget> createState { return TVWidgetState; } } typedef void onFocusChange(bool hasFocus); typedef void onClick; class TVWidgetState extends State<TVWidget> { FocusNode _focusNode; bool init = false; var default_decoration = BoxDecoration( border: Border.all(width: 3, color: Colors.deepOrange), borderRadius: BorderRadius.all( Radius.circular(5), )); var decoration = null; @override void initState { super.initState; _focusNode = FocusNode; _focusNode.addListener( { if (widget.focusChange != null) { widget.focusChange(_focusNode.hasFocus); } if (_focusNode.hasFocus) { setState( { if (widget.hasDecoration) { decoration = widget.decoration == null ? default_decoration : widget.decoration; } }); } else { setState( { decoration = null; }); } }); } @override Widget build(BuildContext context) { if (widget.requestFocus && !init) { FocusScope.of(context).requestFocus(_focusNode); init = true; } return RawKeyboardListener( focusNode: _focusNode, onKey: (event) { if (event is RawKeyDownEvent && event.data is RawKeyEventDataAndroid) { RawKeyDownEvent rawKeyDownEvent = event; RawKeyEventDataAndroid rawKeyEventDataAndroid = rawKeyDownEvent.data; print(keyCode: ${rawKeyEventDataAndroid.keyCode}); switch (rawKeyEventDataAndroid.keyCode) { case 19: //KEY_UP // DefaultFocusTraversal.of(context).inDirection( // FocusScope.of(context).focusedChild, TraversalDirection.up); FocusScope.of(context) .focusInDirection(TraversalDirection.up); break; case 20: //KEY_DOWN FocusScope.of(context) .focusInDirection(TraversalDirection.down); break; case 21: //KEY_LEFT // FocusScope.of(context).requestFocus(focusNodeB0); FocusScope.of(context) .focusInDirection(TraversalDirection.left); // 鎵嬪姩鎸囧畾涓嬩竴涓劍鐐 // FocusScope.of(context).requestFocus(focusNode); break; case 22: //KEY_RIGHT // FocusScope.of(context).requestFocus(focusNodeB1); FocusScope.of(context) .focusInDirection(TraversalDirection.right); // DefaultFocusTraversal.of(context) // .inDirection(_focusNode, TraversalDirection.right); // if(_focusNode.nextFocus){ // FocusScope.of(context) // .focusInDirection(TraversalDirection.right); // } break; case 23: //KEY_CENTER widget.onclick; break; case 66: //KEY_ENTER widget.onclick; break; default: break; } } }, child: Container( margin: EdgeInsets.all(8), decoration: decoration, child: widget.child, )); } } 濂戒簡锛屽叧浜嶧lutter TV寮鍙戝氨璁茶В杩欎箞澶氥

鍏舵锛屽仛骞冲彴涓嶆槸鍋氫竴涓畝鍗曠殑缃戠珯锛屾兂鍚稿紩浼樿川鐨勪緵搴斿晢杩涘叆骞冲彴锛屽氨瑕佹眰骞冲彴蹇呴』涓哄叾鎻愪緵浠峰笺

鍒2020骞村簳姝︽眽甯傚皢寤烘垚2涓囧骇5G鍩虹珯锛屽埌2021骞村簳瀹炵幇5G甯傚煙鍏ㄨ鐩栥

800浣欏勾棣欐鍙ゆ爲涓嶄粎鐙湪鎴愭灄銆佺嫭鑷垚鏅紝鑰屼笖鍥犺璇佸彉杩併佹晠浜嬩紶濂囪屽彈鍒板綋鍦颁袱鏃忔潙姘戞帴鍔涢綈蹇冧繚鎶ゅ拰鏁话浼犳壙锛屾垚涓哄綋鍦扮殑涓娈典匠璇濄

鎬讳綋鑰岃█锛孭ython绋嬪簭鍛樺湪涓嶄箙鐨勫皢鏉ヤ細鏈夋洿濂界殑鑱屼笟鍓嶆櫙銆

03 娣峰悎浜戝埌鍝噷鍘 鎺ヤ笅鏉ユ垜浠湅涓涓嬫贩鍚堜簯瑕佸埌鍝噷鍘汇

銆銆涓嶅悓浜庤叮搴椾互澶х櫧姹借溅銆佸湪绾挎棭鏁欍侀珮绔湇鍔°佹牎鍥ぞ浜ゃ佷氦閫氭帹鑽愭笭閬撶瓑涓轰唬琛ㄧ殑澶ч噺鏂板叴涓氬姟棰嗗湴鐨勫彂鍔涳紝涔愪俊杩戜簺骞存潵涓鐩翠富鏀婚噾铻嶇鎶涓氬姟锛屽苟寮鸿皟鏈潵浼氱户缁姞澶у湪杩欎竴鏂归潰鐨勬姇鍏ャ

2017 骞 3 鏈堬紝浠诲ぉ鍫傛帹鍑轰富鏈恒佹帉鏈哄弻褰㈡佽璁$殑鐢靛瓙娓告垙鏈 Switch锛 闅忓鍙帺銆佸彲瀛樼画鐨勬父鎴忚繘搴︺佷赴瀵岀殑娓告垙搴撹浠诲ぉ鍫傚啀搴﹁耽寰椾簡鐜╁浠殑濂借瘎锛屼綘鏈鍠滄浠诲ぉ鍫傛棗涓嬬殑鍝竴娆炬父鎴忓憿锛 #娆㈣繋鍏虫敞鐖辫寖鍎垮畼鏂瑰井淇″叕浼楀彿锛氱埍鑼冨効锛堝井淇″彿锛歩fanr锛夛紝鏇村绮惧僵鍐呭绗竴鏃堕棿涓烘偍濂変笂銆

鑾峰彇鐒︾偣鍚庨潰浼氳鍒帮紝杩欓噷鏆傛椂涓嶆彁浜嗐

閫氳繃娣峰悎浜戯紝浼犵粺浼佷笟鍦ㄤ繚鎸佽嚜宸辨満鎴夸笌鏍稿績涓氬姟鐨勫悓鏃讹紝鍙互鎶婁竴浜涜竟缂樹笟鍔℃垨鑰呭脊鎬ц姹傞珮鐨勪笟鍔℃斁鍒板叕鍏变簯涓婏紝鑰屼笖杩樿兘鍦ㄤ簯鍘傚晢鐨勫府鍔╀笅鍗囩骇鍐呴儴鐨勬妧鏈灦鏋勶紝涓哄皢鏉ュ仛鍌ㄥ锛屽吋寰楅奔鍜岀唺鎺屻

Java Javs鏄伒寰狤CMA瑙勮寖鐨勯珮绾цВ閲婃ц剼鏈瑷銆

浠婂勾涓婂崐骞达紝瀹d簹鍥介檯閬亣浜忔崯銆

var default_decoration = BoxDecoration( border: Border.all(width: 3, color: Colors.deepOrange), borderRadius: BorderRadius.all( Radius.circular(5), )); ... ... child: Container( margin: EdgeInsets.all(8), decoration: default_decoration, child: widget.child, )); 鏈鍚庣粰澶у涓涓畬鏁寸殑鏈鏂扮殑鎶鏈柟妗堢殑渚嬪瓙浠g爜: 鍏堢粯鍒舵杩庨〉锛屾晥鏋滃浘濡備笅: 浠g爜濡備笅: // 鍚姩娆㈣繋椤 import dart:async; import package:flutter/material.dart; import package:flutter/services.dart; import ui/tv_page.dart; void main => runApp(MyApp); class MyApp extends StatelessWidget { @override Widget build(BuildContext context) { SystemChrome.setEnabledSystemUIOverlays([]); // 寮哄埗妯睆 SystemChrome.setPreferredOrientations([ DeviceOrientation.landscapeLeft, DeviceOrientation.landscapeRight ]); return MaterialApp( title: Flutter TV, debugShowCheckedModeBanner: false, theme: ThemeData( primarySwatch: Colors.blue, ), home: MyHomePage, ); } } class MyHomePage extends StatefulWidget { @override _MyHomePageState createState => _MyHomePageState; } class _MyHomePageState extends State<MyHomePage> { Timer timer; @override void initState { startTimeout; super.initState; } @override Widget build(BuildContext context) { return Scaffold( primary: true, backgroundColor: Colors.black54, body: Center( child: Text( 鑺掓灉TV, style: TextStyle( fontSize: 50, color: Colors.deepOrange, fontWeight: FontWeight.normal), ), ), ); } _toPage { Navigator.pushAndRemoveUntil( context, MaterialPageRoute(builder: (context) => TVPage), (route) => route == null, ); } //鍊掕鏃跺鐞 static const timeout = const Duration(seconds: 3); startTimeout { timer = Timer(timeout, handleTimeout); return timer; } void handleTimeout { _toPage; } @override void dispose { if (timer != null) { timer.cancel; timer = null; } super.dispose; } } 搴旂敤棣栭〉锛屾晥鏋滃浘濡備笅: 浠g爜濡備笅: // 搴旂敤棣栭〉 import dart:async; import package:flutter/material.dart; import package:flutter/services.dart; import package:flutter_tv/utils/time_utils.dart; import package:flutter_tv/widgets/tv_widget.dart; import home_page.dart; import list_page.dart; class TVPage extends StatefulWidget { @override State<StatefulWidget> createState { SystemChrome.setEnabledSystemUIOverlays([]); // 寮哄埗妯睆 SystemChrome.setPreferredOrientations( [DeviceOrientation.landscapeLeft, DeviceOrientation.landscapeRight]); return TVPageState; } } class TVPageState extends State<TVPage> with SingleTickerProviderStateMixin { TabController _tabController; Timer timer; var timeString = TimeUtils.getTime; bool init = false; FocusNode focusNodeB0 = FocusNode; FocusNode focusNodeB1 = FocusNode; @override void initState { super.initState; //initialIndex涓哄垵濮嬮変腑绗嚑涓紝length涓烘暟閲 _tabController = TabController(initialIndex: 0, length: 8, vsync: this); // 鐩戝惉 _tabController.addListener( { switch (_tabController.index) { case 0: break; case 1: break; } }); focusNodeB0.addListener( { if (focusNodeB0.hasFocus) { setState( { _tabController.animateTo(0); }); } }); focusNodeB1.addListener( { if (focusNodeB1.hasFocus) { setState( { _tabController.animateTo(1); }); } }); } @override Widget build(BuildContext context) { return Container( color: Colors.black87, padding: EdgeInsets.all(30), child: Scaffold( appBar: AppBar( backgroundColor: Colors.black87, leading: Icon( Icons.live_tv, color: Colors.deepOrange, size: 50, ), title: Text( 鑺掓灉TV, style: TextStyle( fontSize: 30, color: Colors.white, fontStyle: FontStyle.italic), ), primary: true, actions: <Widget>[ FlatButton( child: Text( $timeString, style: TextStyle(color: Colors.white), ), ), ], // 璁剧疆TabBar bottom: TabBar( controller: _tabController, indicatorColor: Colors.deepOrange, labelColor: Colors.deepOrange, unselectedLabelColor: Colors.white, tabs: <Widget>[ Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(0); }); } }, child: Text( 棣栭〉, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), requestFocus: true, ), ), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(1); }); } }, child: Text( 绮鹃, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), )), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(2); }); } }, onclick: { print(鐐瑰嚮); }, child: Text( 鍥戒骇, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), )), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(3); }); } }, child: Text( 娆х編, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), )), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(4); }); } }, child: Text( 鏃ユ极, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(5); }); } }, child: Text( 浜插瓙, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), Tab( child: TVWidget( hasDecoration: false, focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(6); }); } }, child: Text( 灏戠患, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), Tab( child: TVWidget( focusChange: (hasFocus) { if (hasFocus) { setState( { _tabController.animateTo(7); }); } }, hasDecoration: false, child: Text( 鍒嗙被, style: TextStyle(fontSize: 20, fontWeight: FontWeight.bold), ), ), ), ], ), ), body: TabBarView( controller: _tabController, children: <Widget>[ HomePage, ListPage, HomePage, ListPage, HomePage, ListPage, HomePage, ListPage, ], ), ), ); } startTimeout { timer = Timer.periodic(Duration(minutes: 1), (t) { setState( { timeString = TimeUtils.getTime; }); }); } @override void dispose { if (timer != null) { timer.cancel; timer == null; } super.dispose; } } // TAB椤甸潰涓殑鍏朵腑涓涓〉闈紝鍏朵粬绫讳技 import package:flutter/material.dart; import package:flutter/widgets.dart; import package:flutter_tv/widgets/tv_widget.dart; class HomePage extends StatefulWidget { const HomePage({ Key key, @required this.index, }) : super(key: key); final int index; @override State<StatefulWidget> createState { return HomePageState; } } class HomePageState extends State<HomePage> with AutomaticKeepAliveClientMixin { @override void initState { super.initState; } @override Widget build(BuildContext context) { return Container( color: Colors.black87, child: Row( children: <Widget>[ Flexible( child: Column( children: <Widget>[ _buildItem(0), _buildItem(1), _buildItem(2), ], ), flex: 1, ), Flexible( child: Column( children: <Widget>[ _buildImageItem(3, 2), Expanded( flex: 1, child: Row( children: <Widget>[ _buildImageItem(4, 1), _buildImageItem(5, 1), ], )), ], ), flex: 4, ), Flexible( child: Column( children: <Widget>[ _buildImageItem(6, 2), _buildImageItem(7, 1), ], ), flex: 2, ), Flexible( child: Column( children: <Widget>[ _buildImageItem(8, 2), _buildImageItem(9, 1), ], ), flex: 2, ), ], ), ); } _buildItem(int index) { return Expanded( child: TVWidget( focusChange: (hasfocus) {}, child: Container( width: MediaQuery.of(context).size.width, child: GestureDetector( child: Card( elevation: 5, margin: EdgeInsets.all(0), color: _colors.elementAt(index), child: Container( child: Column( crossAxisAlignment: CrossAxisAlignment.center, mainAxisAlignment: MainAxisAlignment.center, children: <Widget>[ _icons.elementAt(index), _title.elementAt(index), ], ), ), ), onTap: { _click(index); }, ), )), flex: 1, ); } _buildImageItem(int index, int flex) { return Expanded( child: TVWidget( child: Container( width: MediaQuery.of(context).size.width, child: GestureDetector( child: Card( elevation: 5, margin: EdgeInsets.all(0), color: _colors.elementAt(index), child: Container( child: Stack( alignment: Alignment.bottomLeft, children: <Widget>[ ClipRRect( child: Image.asset( _images.elementAt(index), fit: BoxFit.fill, width: MediaQuery.of(context).size.width, height: MediaQuery.of(context).size.height, ), borderRadius: BorderRadius.all( Radius.circular(5), ), ), Container( width: MediaQuery.of(context).size.width, child: Column( mainAxisSize: MainAxisSize.min, crossAxisAlignment: CrossAxisAlignment.start, children: <Widget>[ _title.elementAt(index), index == 3 ? _des.elementAt(index) : SizedBox( height: 0, ), ], ), color: _colors.elementAt(index).withAlpha(240), padding: EdgeInsets.all(5), ), ], ), ), ), onTap: { _click(index); }, ), ), focusChange: (hasfocus) {}, ), flex: flex, ); } void _click(int index) { switch (index) { case 0: break; case 4: // Navigator.push(context, MaterialPageRoute(builder: (context) { // return AboutPage; // })); break; } } List<Icon> _icons = [ Icon( Icons.search, size: 38, color: Colors.white, ), Icon( Icons.history, size: 38, color: Colors.white, ), Icon( Icons.event, size: 38, color: Colors.white, ), Icon( Icons.share, size: 38, color: Colors.deepPurpleAccent, ), Icon( Icons.error_outline, size: 38, color: Colors.orange, ), Icon( Icons.settings, size: 38, color: Colors.red, ) ]; List<String> _images = [ assets/htpy.jpg, assets/htpy.jpg, assets/htpy.jpg, assets/htpy.jpg, assets/agzz.jpg, assets/amypj.jpg, assets/hmjz.jpg, assets/dxflqm.jpg, assets/lifeandpi.jpg, assets/nanasqc.jpg, ]; List<Color> _colors = [ Colors.red, Colors.orange, Colors.green, Colors.red, Colors.orange, Colors.green, Colors.orange, Colors.orange, Colors.orange, Colors.orange, ]; List<Text> _title = [ Text( 鎼滅储, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鍘嗗彶, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 涓撻, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鐜お骞虫磱, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 闃跨敇姝d紶, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鍌叉參涓庡亸瑙, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 榛戠尗璀﹂暱, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 褰撳垢绂忔潵鏁查棬, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( Life Or PI, style: TextStyle(color: Colors.white, fontSize: 18), ), Text( 鍝晩鍝晩绁炲幓鏉, style: TextStyle(color: Colors.white, fontSize: 18), ), ]; List<Text> _des = [ Text( 闈炲父濂界湅鐨勭數褰, style: TextStyle(color: Colors.white, fontSize: 12), ), Text( 璁剧疆瀵嗙爜閿, style: TextStyle(color: Colors.white, fontSize: 12), ), Text( 鍚愭Ы鍙嶉浣犵殑鎯虫硶, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), Text( 闈炲父濂界湅鐨勭數褰, style: TextStyle(color: Colors.white, fontSize: 12), ), Text( 鐗堟湰淇℃伅, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), Text( 绯荤粺鐩稿叧璁剧疆, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), Text( 绯荤粺鐩稿叧璁剧疆, style: TextStyle(color: Color.fromRGBO(162, 162, 162, 1), fontSize: 16), ), ]; @override // TODO: implement wantKeepAlive bool get wantKeepAlive => true; } 灏佽鐨勬牳蹇冪被: // 灏佽鐨勬牳蹇冪劍鐐瑰鐞嗙被 import package:flutter/material.dart; import package:flutter/services.dart; import package:flutter/widgets.dart; class TVWidget extends StatefulWidget { TVWidget( {Key key, @required this.child, @required this.focusChange, @required this.onclick, @required this.decoration, @required this.hasDecoration = true, @required this.requestFocus = false}) : super(key: key); Widget child; onFocusChange focusChange; onClick onclick; bool requestFocus; BoxDecoration decoration; bool hasDecoration; @override State<StatefulWidget> createState { return TVWidgetState; } } typedef void onFocusChange(bool hasFocus); typedef void onClick; class TVWidgetState extends State<TVWidget> { FocusNode _focusNode; bool init = false; var default_decoration = BoxDecoration( border: Border.all(width: 3, color: Colors.deepOrange), borderRadius: BorderRadius.all( Radius.circular(5), )); var decoration = null; @override void initState { super.initState; _focusNode = FocusNode; _focusNode.addListener( { if (widget.focusChange != null) { widget.focusChange(_focusNode.hasFocus); } if (_focusNode.hasFocus) { setState( { if (widget.hasDecoration) { decoration = widget.decoration == null ? default_decoration : widget.decoration; } }); } else { setState( { decoration = null; }); } }); } @override Widget build(BuildContext context) { if (widget.requestFocus && !init) { FocusScope.of(context).requestFocus(_focusNode); init = true; } return RawKeyboardListener( focusNode: _focusNode, onKey: (event) { if (event is RawKeyDownEvent && event.data is RawKeyEventDataAndroid) { RawKeyDownEvent rawKeyDownEvent = event; RawKeyEventDataAndroid rawKeyEventDataAndroid = rawKeyDownEvent.data; print(keyCode: ${rawKeyEventDataAndroid.keyCode}); switch (rawKeyEventDataAndroid.keyCode) { case 19: //KEY_UP // DefaultFocusTraversal.of(context).inDirection( // FocusScope.of(context).focusedChild, TraversalDirection.up); FocusScope.of(context) .focusInDirection(TraversalDirection.up); break; case 20: //KEY_DOWN FocusScope.of(context) .focusInDirection(TraversalDirection.down); break; case 21: //KEY_LEFT // FocusScope.of(context).requestFocus(focusNodeB0); FocusScope.of(context) .focusInDirection(TraversalDirection.left); // 鎵嬪姩鎸囧畾涓嬩竴涓劍鐐 // FocusScope.of(context).requestFocus(focusNode); break; case 22: //KEY_RIGHT // FocusScope.of(context).requestFocus(focusNodeB1); FocusScope.of(context) .focusInDirection(TraversalDirection.right); // DefaultFocusTraversal.of(context) // .inDirection(_focusNode, TraversalDirection.right); // if(_focusNode.nextFocus){ // FocusScope.of(context) // .focusInDirection(TraversalDirection.right); // } break; case 23: //KEY_CENTER widget.onclick; break; case 66: //KEY_ENTER widget.onclick; break; default: break; } } }, child: Container( margin: EdgeInsets.all(8), decoration: decoration, child: widget.child, )); } } 濂戒簡锛屽叧浜嶧lutter TV寮鍙戝氨璁茶В杩欎箞澶氥

銆 姝ゅ锛岄浄鍐涜繕琛ㄧず灏忕背 9 Pro 灏嗛厤澶 4000mAh 鐢垫睜锛屼繚鎸佽交钖勶紝涓嶆槸銆屽崐鏂ゆ満銆嶏紝杩樺皢鏀寔 NFC銆宔ID 鐢靛瓙韬唤璇併嶏紝鍙洿鎺ョ敤鎵嬫満鍧愰珮閾併佸潗椋炴満銆佸叆浣忛厭搴椼

3. 鐧婚棬妲涙晥搴 瀹氫箟锛氬張绉板緱瀵歌繘灏烘晥搴旓紝鏄寚涓涓汉涓鏃︽帴鍙椾簡浠栦汉鐨勪竴涓井涓嶈冻閬撶殑瑕佹眰锛屼负浜嗛伩鍏嶈鐭ヤ笂鐨勪笉鍗忚皟锛屾垨鎯崇粰浠栦汉浠ュ墠鍚庝竴鑷寸殑鍗拌薄锛屽氨鏈夊彲鑳芥帴鍙楁洿澶х殑瑕佹眰銆

鑰屼綔涓哄紑鍙戝伐鍏风殑Rails锛屼负Web寮鍙戜汉鍛樻彁渚涗簡缂栧啓浠g爜鐨勬鏋跺拰缁撴瀯锛屾湁鍔╀簬鍚勭缃戠珯鍜屽簲鐢ㄧ殑鏋勫缓銆

杩欐槸鐩掗┈涓庝腹楹︾殗鍐犻泦鍥㈠叡鍚屼负涓浗娑堣垂鑰呭紑鍙戠殑鏂颁骇鍝侊紝鍏舵禉姹熷钩婀栫殑鏂板伐鍘傚垰寤烘垚锛岃繖鍑犳鐚倝灏辨槸浠庝腹楹﹁繘鍙o紝鍦ㄥ钩婀栧伐鍘傚畬鎴愬姞宸ュ苟鍒囧垎銆佸寘瑁呮垚绗﹀悎涓浗娑堣垂鑰呴ギ椋熶範鎯殑鍟嗗搧锛岀洿杈剧洅椹揣鏋躲

浜у搧涓殑搴旂敤锛氫笉鐭ラ亾澶у杩樿涓嶈寰楀幓骞寸殑娣樺疂鍙11鍚堜紮缁勬垬闃熼泦鑳介噺鐨勭帺娉曪紝澹板娍娴╁ぇ锛屼篃鍙栧緱浜嗗緢濂界殑鏁堟灉銆

銆銆鏍规嵁鎶ラ亾鏄剧ず锛屽ぇ瀛︾敓鍦ㄤ箰淇℃棗涓嬪垎鏈熶箰骞冲彴涓婂~鍐欐鍦ㄥ氨璇荤殑瀛︽牎鍜屽叆瀛︽椂闂寸瓑淇℃伅鍚庯紝浠嶇劧鑳藉椤哄埄鍦拌繘琛屽熸锛岃屼箰淇℃柟闈㈢殑瑙i噴涓哄彧瑕佸勾婊18鍛ㄥ瞾灏卞彲浠ョ敵璇峰熸锛屼笌鏄笉鏄鐢熸棤鍏炽

鐩墠锛岃澶歐eb鎵樼鎻愪緵鍟嗛兘鑳藉涓哄叾瀹㈡埛鎻愪緵瀵逛簬PHP鐨勬敮鎸併