本文整理汇总了C#中EditText.SetMinHeight方法的典型用法代码示例。如果您正苦于以下问题:C# EditText.SetMinHeight方法的具体用法?C# EditText.SetMinHeight怎么用?C# EditText.SetMinHeight使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类EditText
的用法示例。
在下文中一共展示了EditText.SetMinHeight方法的1个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: OnCreate
protected override void OnCreate(Bundle bundle)
{
base.OnCreate(bundle);
Window.AddFlags(WindowManagerFlags.KeepScreenOn);
SetContentView(Resource.Layout.ExecutionLog);
LoadExtras();
if (Action == "dumpInfo")
{
var layout=FindViewById<LinearLayout>(Resource.Id.executionLayout);
var edit = new EditText(this);
edit.SetMinHeight(100);
// edit.LayoutParameters = (Android.Views.ViewGroup.LayoutParams) Android.Views.ViewGroup.LayoutParams.MatchParent; // WindowManagerLayoutParams.MatchParent; // | WindowManagerLayoutParams.FillParent;
layout.AddView(edit);
ConfigText = edit;
}
if (bundle != null)
{
var second = new Intent(this, typeof(MainActivity));
StartActivity(second);
//FindViewById<TextView>(Resource.Id.terminalOutput).Text = bundle.GetString("output");
//FindViewById<TextView>(Resource.Id.terminalOutput).Text = foobar;
}
if (bundle==null)
{
FindViewById<TextView>(Resource.Id.terminalOutput).MovementMethod = new ScrollingMovementMethod();
Logger = new TextLogger((s) =>
{
RunOnUiThread(() =>
{
var textview=FindViewById<TextView>(Resource.Id.terminalOutput);
textview.Append(s + "\n");
if(bundle!=null)
{
//bundle.PutString("output", textview.Text);
}
var scrollview=FindViewById<ScrollView>(Resource.Id.scrollView1);
//scrollview.FullScroll(FocusSearchDirection.Down);
});
});
FindViewById<TextView>(Resource.Id.terminalOutput).Text="";
Task.Run(() => {
Logger.Log("This may take a few seconds.. Be patient");
switch (Action)
{
case "reboot":
Reboot(Address, Password);
break;
case "enableBridge":
EnableBridge(Address, Password);
break;
case "disableBridge":
DisableBridge(Address, Password);
break;
case "fixRedirect":
FixRedirect(Address, Password);
break;
case "enableTelnet":
EnableTelnet(Address, Password);
break;
case "disableTelnet":
DisableTelnet(Address, Password);
break;
case "factoryReset":
FactoryReset(Address, Password);
break;
case "enableUpnp":
EnableUpnp(Address, Password);
break;
case "disableUpnp":
Execute(Address, Password, x => x.DisableUpnp());
break;
case "disableDhcp":
Execute(Address, Password, x => x.DisableDhcp());
break;
case "enableDhcp":
Execute(Address, Password, x => x.EnableDhcp());
break;
case "dumpInfo":
DumpInfo(Address, Password);
break;
default:
throw new NotImplementedException();
}
});
}
// Create your application here
}