This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public async Task<DependencyObject> GetElementAsync(IElementReference elementReference, Visual viewToSearchIn) | |
{ | |
string elementReferenceType = elementReference.Type.Description.ToLower(); | |
if (elementReferenceType.Equals("viewcommand")) | |
{ | |
return GetViewCommandButton(viewToSearchIn, elementReference); | |
} | |
else | |
{ | |
matchedElements = new List<MatchedElement>(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public IEnumerable<DependencyObject> ScanElementsOnMatch(IElementReference elementReference, DependencyObject viewToSearchIn) | |
{ | |
string elementReferenceType = elementReference.Type.Description.ToLower(); | |
int childrenCount = 0; | |
Application.Current.Dispatcher.Invoke(() => { childrenCount = VisualTreeHelper.GetChildrenCount(viewToSearchIn); }); | |
for (var i = 0; i < childrenCount; i++) | |
{ | |
DependencyObject child = null; | |
Application.Current.Dispatcher.Invoke(() => { child = VisualTreeHelper.GetChild(viewToSearchIn, i); }); | |
foreach (DependencyObject meuk in ScanElementsOnMatch(elementReference, child)) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public static IEnumerable<T> SelectRecursive<T>(DependencyObject involvedView, Func<T, IEnumerable<T>> selector) | |
{ | |
int childrenCount = 0; | |
Application.Current.Dispatcher.Invoke(() => { childrenCount = VisualTreeHelper.GetChildrenCount(involvedView); }); | |
for (var i = 0; i < childrenCount; i++) | |
{ | |
foreach (T child in selector(involvedView).SelectRecursive(selector)) | |
{ | |
yield return child; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<cs:CollectionView x:Class="ChipSoft.Ezis.AutomatedTesting.Views.ScriptsView" | |
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation" | |
xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml" | |
xmlns:cs="http://chipsoft.com/core/presentation" | |
Title="{Binding Title}" | |
CurrentCollection="{Binding CurrentCollection}" | |
CurrentObject="{Binding CurrentObject}" | |
SelectedCollection="{Binding SelectedCollection}" | |
IsMultiSelect="{Binding IsMultiSelect}" | |
cs:ViewLayout.Id="ID" cs:ViewLayout.SubId="SUBID" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
public ObservableField<Integer> total = new ObservableField<>(); | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"Hey girl did you just went through a chemo, cause you are shining!" |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@Entity(tableName = "rack", indices = { @Index("id"), @Index("storage_id") }, | |
foreignKeys = { | |
@ForeignKey( | |
entity = Storage.class, | |
parentColumns = {"id"}, | |
childColumns = {"storage_id"}, | |
onDelete = ForeignKey.CASCADE, | |
onUpdate = ForeignKey.CASCADE | |
)} | |
) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* | |
Created by Martijn Bakker with help from 'Learn Web Development' | |
*/ | |
// HTML class // | |
class DOMElements { | |
constructor() { | |
this.cvs = document.getElementById("canvas_snake_game"); | |
this.menu = document.getElementById("menu"); | |
this.setName = document.getElementById("set_name"); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// returns allRacks with correct storage_id | |
public LiveData<List<UIStorage>> getStorageUnits() | |
{ | |
getExecutor().execute(() -> | |
{ | |
Transformations.map(getDao().getStorageUnits(), newData -> createStorageUIList(newData)); | |
}); | |
return ??? | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
storageRepository.getStorageUnits(executor).observe(owner, storageUnits -> | |
{ | |
executor.execute(() -> | |
{ | |
for (UIStorage uiStorage : storageUnits) | |
{ | |
storageRepository.setUIStorageElements(uiStorage, imgProcessor); | |
} | |
storageListAdapterObsv.set(new StorageListAdapter(storageUnits, mainViewCmdHandlerCallBack)); | |
}); |