mirror of
https://github.com/bitwarden/mobile
synced 2025-12-13 23:03:23 +00:00
vault groupings page list view stubbed
This commit is contained in:
@@ -1,38 +1,15 @@
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Runtime.CompilerServices;
|
||||
using Bit.Core.Utilities;
|
||||
|
||||
namespace Bit.App.Pages
|
||||
{
|
||||
public abstract class BaseViewModel : INotifyPropertyChanged
|
||||
public abstract class BaseViewModel : ExtendedViewModel
|
||||
{
|
||||
private string _pageTitle = string.Empty;
|
||||
|
||||
public event PropertyChangedEventHandler PropertyChanged;
|
||||
|
||||
public string PageTitle
|
||||
{
|
||||
get => _pageTitle;
|
||||
set => SetProperty(ref _pageTitle, value);
|
||||
}
|
||||
|
||||
protected bool SetProperty<T>(ref T backingStore, T value, [CallerMemberName]string propertyName = "",
|
||||
Action onChanged = null)
|
||||
{
|
||||
if(EqualityComparer<T>.Default.Equals(backingStore, value))
|
||||
{
|
||||
return false;
|
||||
}
|
||||
backingStore = value;
|
||||
onChanged?.Invoke();
|
||||
OnPropertyChanged(propertyName);
|
||||
return true;
|
||||
}
|
||||
|
||||
protected void OnPropertyChanged([CallerMemberName] string propertyName = "")
|
||||
{
|
||||
PropertyChanged?.Invoke(this, new PropertyChangedEventArgs(propertyName));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user