我首先在我的应用程序中使用Material设计,我的问题是当我创建活动时没有操作栏或工具栏但是我有Material Navigation抽屉为什么它没有像旧版本那样自动实现活动布局:
<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
android:orientation="vertical"
android:layout_width="match_parent"
android:layout_height="match_parent">
<TextView
android:layout_width="wrap_content"
android:layout_height="wrap_content"
android:text="New Text"
android:id="@+id/textView4" />
</LinearLayout>
Run Code Online (Sandbox Code Playgroud)
活动:包装碎片;
import android.os.Bundle;
import android.support.v7.app.ActionBarActivity;
import android.view.Menu;
public class Noname1 extends ActionBarActivity{
@Override
protected void onCreate(Bundle savedInstanceState) {
super.onCreate(savedInstanceState);
setContentView(R.layout.test);
}
@Override
public boolean onCreateOptionsMenu(Menu menu) {
getMenuInflater().inflate(R.menu.main, menu);
return super.onCreateOptionsMenu(menu);
}
Run Code Online (Sandbox Code Playgroud)
我的主题:
<style name="AppTheme" parent="Theme.AppCompat.NoActionBar">
<!-- Customize your theme here. -->
<item name="colorPrimary">@color/nliveo_green_colorPrimary</item>
<item name="colorPrimaryDark">@color/nliveo_green_colorPrimaryDark</item>
<item name="colorAccent">@color/nliveo_green_colorPrimary</item>
<item name="android:textColorPrimary">@color/myTextPrimaryColor</item>
<item name="drawerArrowStyle">@style/DrawerArrowStyle</item>
<item name="android:windowBackground">@color/myWindowBackground</item>
</style>
Run Code Online (Sandbox Code Playgroud) 您好我有以下视图,他们与Extjs 4.1库工作得很好,但知道我使用5.1版本,当我尝试使用它时,它不会在doLayout()上显示pproperly并显示Uncaught TypeError:无法读取属性'tooNarrow'的undefined .我是Extjs的新手也许在5.1库中有不同的选项,我不知道?请帮助
拳头我试图加载PersonPanelView:
PersonPanelView:
Ext.define('Pandora.view.Person.PersonPanelView', {
extend: 'Ext.panel.Panel',
alias: 'widget.PersonPanel',
layout: 'hbox',
items:[
{
flex:1.8,
xtype:'PersonList',
height:'100%',
title:'List of persons'
},
{
flex:3,
height:'100%',
xtype:'panel',
id:'personProfileId',
autoScroll:true,
title:'Person profile',
//frame:true,
bodyStyle:{background: '#99bce8'}
}
]
});
Run Code Online (Sandbox Code Playgroud)
PersonList:
Ext.define('Pandora.view.Person.PersonListView', {
extend: 'Ext.grid.Panel',
alias: 'widget.PersonList',
layout: 'border',
title: 'Person',
store: 'Person.PersonStore',
autoScroll:true,
dockedItems:[
{
tbar:[
{ xtype:'button', text:'Add Person',name:'addPerson' },'-',
{ xtype:'button', text:'Edit Person',name:'editPerson' },'-',
{ xtype:'button', text:'Remove Person',name:'removePerson' },'-',
{ xtype:'button', text:'Add Conference',name:'addConference'},'-',
{ xtype:'button', text:'Add Event',name:'addEvent'}
]
}
], …Run Code Online (Sandbox Code Playgroud) 你好如何从另一个 Json 数组中的 Json 数组获取数据我已经获取数据直到附件但附件不起作用,所有代码工作直到附件如何从附件中获取数据我需要从中获取“photo_75”
杰森
"response":{
"count":3,
"items":[
{
"id":3,
"from_id":205110032,
"owner_id":-81865402,
"date":1417672154,
"post_type":"post",
"text":"jjjjASDFGHJKYTRDXCVB",
"attachments":[
{
"type":"photo",
"photo":{
"id":330414711,
"album_id":-7,
"owner_id":205110032,
"photo_75":"http:\/\/cs605116.vk.me\/v605116032\/6325\/3SwTo8j4lJ0.jpg",
"photo_130":"http:\/\/cs605116.vk.me\/v605116032\/6326\/_OZA86FO3Nw.jpg",
"photo_604":"http:\/\/cs605116.vk.me\/v605116032\/6327\/AUtB59708Nw.jpg",
"photo_807":"http:\/\/cs605116.vk.me\/v605116032\/6328\/59oAdfz9jgI.jpg",
"width":538,
"height":807,
"text":"",
"date":1399134687,
"access_key":"7297eb663de2e4e6b2"
}
}
],
"comments":{
"count":0
},
"likes":{
"count":0
},
"reposts":{
"count":0
}
},
Run Code Online (Sandbox Code Playgroud)
爪哇
private void parseJsonFeed(JSONObject response) {
try {
JSONObject parent = response.getJSONObject("response");
JSONArray feedArray = parent.getJSONArray("items");
for (int i = 0; i < feedArray.length(); i++) {
JSONObject feedObj = (JSONObject) feedArray.get(i);
FeedItem item = new …Run Code Online (Sandbox Code Playgroud)