Wip theme+estimate
This commit is contained in:
parent
c00b38f16c
commit
6c409d6d71
12 changed files with 253 additions and 125 deletions
|
|
@ -16,7 +16,10 @@ namespace BookAStar.Pages
|
|||
public Estimate Estimate { get { return BindingContext as Estimate; } set {
|
||||
BindingContext = value;
|
||||
} }
|
||||
public static readonly BindableProperty MarkdownProperty =
|
||||
public static readonly BindableProperty TotalProperty =
|
||||
BindableProperty.Create("Total", typeof(decimal), typeof(EditEstimatePage),
|
||||
(decimal) 0, BindingMode.OneWay);
|
||||
public static readonly BindableProperty DescriptionProperty =
|
||||
BindableProperty.Create("Description", typeof(string), typeof(Estimate),
|
||||
null, BindingMode.TwoWay);
|
||||
public static readonly BindableProperty ClientProperty =
|
||||
|
|
@ -26,19 +29,31 @@ namespace BookAStar.Pages
|
|||
BindableProperty.Create("Query", typeof(BookQueryData), typeof(Estimate),
|
||||
null, BindingMode.OneWay);
|
||||
|
||||
|
||||
|
||||
public EditEstimatePage()
|
||||
{
|
||||
InitializeComponent();
|
||||
}
|
||||
|
||||
protected override void OnBindingContextChanged()
|
||||
{
|
||||
base.OnBindingContextChanged();
|
||||
mdview.Markdown = Estimate?.Description;
|
||||
// FIXME Why the Binding don't work?
|
||||
mdview.Markdown = Estimate.Description;
|
||||
|
||||
}
|
||||
|
||||
protected void OnDescriptionChanged (object sender, EventArgs e)
|
||||
{
|
||||
// FIXME Why the Binding don't work?
|
||||
Estimate.Description = mdview.Markdown;
|
||||
}
|
||||
protected void OnNewCommanLine(object sender, EventArgs e)
|
||||
{
|
||||
var com = new CommandLine();
|
||||
App.CurrentApp.EditCommandLine(com);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue