Beispiel #1
0
 private void SetBreakpointValues(OrderOption value, params Breakpoint[] breakpoints)
 {
     foreach (var breakpoint in breakpoints)
     {
         this.breakpointDictionary[breakpoint] = value;
     }
 }
Beispiel #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="FluentOrder"/> class.
 /// </summary>
 /// <param name="initialValue">The default item order.</param>
 public FluentOrder(OrderOption initialValue)
 {
     this.breakpointDictionary.Add(Breakpoint.Mobile, initialValue);
     this.breakpointDictionary.Add(Breakpoint.Tablet, initialValue);
     this.breakpointDictionary.Add(Breakpoint.Desktop, initialValue);
     this.breakpointDictionary.Add(Breakpoint.Widescreen, initialValue);
     this.breakpointDictionary.Add(Breakpoint.FullHD, initialValue);
 }
Beispiel #3
0
 /// <inheritdoc/>
 public IFluentOrder OnMobileAndLarger(OrderOption option)
 {
     this.SetBreakpointValues(option, Breakpoint.Mobile, Breakpoint.Tablet, Breakpoint.Desktop, Breakpoint.Widescreen, Breakpoint.FullHD);
     return(this);
 }
Beispiel #4
0
 /// <inheritdoc/>
 public IFluentOrder OnMobile(OrderOption option)
 {
     this.breakpointDictionary[Breakpoint.Mobile] = option;
     return(this);
 }
Beispiel #5
0
 /// <inheritdoc/>
 public IFluentOrder OnFullHD(OrderOption option)
 {
     this.breakpointDictionary[Breakpoint.FullHD] = option;
     return(this);
 }
Beispiel #6
0
 /// <inheritdoc/>
 public IFluentOrder OnDesktopAndSmaller(OrderOption option)
 {
     this.SetBreakpointValues(option, Breakpoint.Mobile, Breakpoint.Tablet, Breakpoint.Desktop);
     return(this);
 }
Beispiel #7
0
 /// <inheritdoc/>
 public IFluentOrder OnDesktop(OrderOption option)
 {
     this.breakpointDictionary[Breakpoint.Desktop] = option;
     return(this);
 }
Beispiel #8
0
 /// <inheritdoc/>
 public IFluentOrder OnWidescreenAndLarger(OrderOption option)
 {
     this.SetBreakpointValues(option, Breakpoint.Widescreen, Breakpoint.FullHD);
     return(this);
 }
Beispiel #9
0
 /// <inheritdoc/>
 public IFluentOrder OnWidescreen(OrderOption option)
 {
     this.breakpointDictionary[Breakpoint.Widescreen] = option;
     return(this);
 }
Beispiel #10
0
 /// <inheritdoc/>
 public IFluentOrder OnTablet(OrderOption option)
 {
     this.breakpointDictionary[Breakpoint.Tablet] = option;
     return(this);
 }