Inherits Foodolini::Activities::IActivity.
Public Member Functions | |
ShoppingListActivity () | |
void | Register (IOwner owner) |
Subscribe to the events exposed by owner, and store a reference to owner. | |
void | Unregister () |
Unsubscribe to the events exposed by owner, and loose any references to owner. | |
void | AddRecipe (Recipe recipe, double servings) |
Add all ingredients needed for the recipe to the shoppinglist. | |
Protected Member Functions | |
virtual void | Build () |
virtual void | OnBtnClearActivated (object sender, System.EventArgs e) |
virtual void | OnBtnAddIngredientClicked (object sender, System.EventArgs e) |
virtual void | OnBtnPrintClicked (object sender, System.EventArgs e) |
Prints the shopping shoppingList. | |
virtual void | OnBtnCookbookClicked (object sender, System.EventArgs e) |
Goes to the cookbook activity. | |
virtual void | OnBtnDeleteClicked (object sender, System.EventArgs e) |
Deletes an item from the shopping shoppingList. | |
virtual void | OnShoppingListViewerCursorChanged (object sender, System.EventArgs e) |
virtual void | OnShoppingListViewerRowActivated (object o, Gtk.RowActivatedArgs args) |
Changes the ingredient in shoppinglist item. | |
Properties | |
Widget | Widget [get] |
Private Member Functions | |
void | OwnerhandleCurrentUserChanged (object sender, PersonEventArgs e) |
void | LoadShoppingListData () |
Loads shopping list data for the current user and binds the data to the treeview. | |
void | SetDeleteButtonState () |
void | ShowIngredientAlreadyAddedMessage () |
Private Attributes | |
Gtk.VBox | vbox2 |
Gtk.ScrolledWindow | GtkScrolledWindow |
Gtk.NodeView | shoppingListViewer |
Gtk.HBox | hbox1 |
Gtk.Button | btnCookbook |
Gtk.Button | btnAddIngredient |
Gtk.Button | btnPrint |
Gtk.Button | btnDelete |
Gtk.Button | btnClear |
NodeStore | shoppingListStore |
Foodolini.BusinessLogic.ShoppingList | shoppingList |
Person | currentUser |
IOwner | owner |
Definition at line 14 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Foodolini.Activities.ShoppingList.ShoppingListActivity.ShoppingListActivity | ( | ) |
Definition at line 20 of file ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.AddRecipe | ( | Recipe | recipe, | |
double | servings | |||
) |
Add all ingredients needed for the recipe to the shoppinglist.
This is all ingredients, and does not depend on what is on storage. If the nature of the shoppinglist is changed in the future, this may change.
Definition at line 122 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.Build | ( | ) | [protected, virtual] |
Definition at line 34 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.LoadShoppingListData | ( | ) | [private] |
Loads shopping list data for the current user and binds the data to the treeview.
Definition at line 77 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnBtnAddIngredientClicked | ( | object | sender, | |
System.EventArgs | e | |||
) | [protected, virtual] |
Definition at line 101 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnBtnClearActivated | ( | object | sender, | |
System.EventArgs | e | |||
) | [protected, virtual] |
Definition at line 95 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnBtnCookbookClicked | ( | object | sender, | |
System.EventArgs | e | |||
) | [protected, virtual] |
Goes to the cookbook activity.
sender | ||
e |
Definition at line 291 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnBtnDeleteClicked | ( | object | sender, | |
System.EventArgs | e | |||
) | [protected, virtual] |
Deletes an item from the shopping shoppingList.
sender | ||
e |
Definition at line 301 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnBtnPrintClicked | ( | object | sender, | |
System.EventArgs | e | |||
) | [protected, virtual] |
Prints the shopping shoppingList.
sender | ||
e |
Definition at line 135 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnShoppingListViewerCursorChanged | ( | object | sender, | |
System.EventArgs | e | |||
) | [protected, virtual] |
Definition at line 317 of file ShoppingListActivity.cs.
virtual void Foodolini.Activities.ShoppingList.ShoppingListActivity.OnShoppingListViewerRowActivated | ( | object | o, | |
Gtk.RowActivatedArgs | args | |||
) | [protected, virtual] |
Changes the ingredient in shoppinglist item.
o | A System.Object | |
args | A Gtk.RowActivatedArgs |
Definition at line 331 of file ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.OwnerhandleCurrentUserChanged | ( | object | sender, | |
PersonEventArgs | e | |||
) | [private] |
Definition at line 61 of file ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.Register | ( | IOwner | owner | ) |
Subscribe to the events exposed by owner, and store a reference to owner.
owner | Instance of an implementation of IOwner |
Implements Foodolini.Activities.IActivity.
Definition at line 32 of file ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.SetDeleteButtonState | ( | ) | [private] |
Definition at line 309 of file ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.ShowIngredientAlreadyAddedMessage | ( | ) | [private] |
Definition at line 347 of file ShoppingListActivity.cs.
void Foodolini.Activities.ShoppingList.ShoppingListActivity.Unregister | ( | ) |
Unsubscribe to the events exposed by owner, and loose any references to owner.
Implements Foodolini.Activities.IActivity.
Definition at line 89 of file ShoppingListActivity.cs.
Gtk.Button Foodolini.Activities.ShoppingList.ShoppingListActivity.btnAddIngredient [private] |
Definition at line 26 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Gtk.Button Foodolini.Activities.ShoppingList.ShoppingListActivity.btnClear [private] |
Definition at line 32 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Gtk.Button Foodolini.Activities.ShoppingList.ShoppingListActivity.btnCookbook [private] |
Definition at line 24 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Gtk.Button Foodolini.Activities.ShoppingList.ShoppingListActivity.btnDelete [private] |
Definition at line 30 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Gtk.Button Foodolini.Activities.ShoppingList.ShoppingListActivity.btnPrint [private] |
Definition at line 28 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Definition at line 18 of file ShoppingListActivity.cs.
Gtk.ScrolledWindow Foodolini.Activities.ShoppingList.ShoppingListActivity.GtkScrolledWindow [private] |
Definition at line 18 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Gtk.HBox Foodolini.Activities.ShoppingList.ShoppingListActivity.hbox1 [private] |
Definition at line 22 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Definition at line 30 of file ShoppingListActivity.cs.
Foodolini.BusinessLogic.ShoppingList Foodolini.Activities.ShoppingList.ShoppingListActivity.shoppingList [private] |
Definition at line 17 of file ShoppingListActivity.cs.
NodeStore Foodolini.Activities.ShoppingList.ShoppingListActivity.shoppingListStore [private] |
Definition at line 16 of file ShoppingListActivity.cs.
Gtk.NodeView Foodolini.Activities.ShoppingList.ShoppingListActivity.shoppingListViewer [private] |
Definition at line 20 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Gtk.VBox Foodolini.Activities.ShoppingList.ShoppingListActivity.vbox2 [private] |
Definition at line 16 of file Foodolini.Activities.ShoppingList.ShoppingListActivity.cs.
Widget Foodolini.Activities.ShoppingList.ShoppingListActivity.Widget [get] |
Implements Foodolini.Activities.IActivity.
Definition at line 26 of file ShoppingListActivity.cs.