public List <Activity> Activity(PageParameters?pageParameters = null, SortingParameters?sortingParameters = null) { Action <RestRequest> prepareRequest = (RestRequest request) => { AddPagingParameters(pageParameters, request); AddSortingParameters(sortingParameters, request); }; return(CallEndpoint <List <Activity> > ("activity", prepareRequest)); }
public List <Branding> Branding(PageParameters?pageParameters = null, SortingParameters?sortingParameters = null) { Action <RestRequest> prepareRequest = (RestRequest request) => { AddPagingParameters(pageParameters, request); AddSortingParameters(sortingParameters, request); }; return(CallEndpoint <List <Branding> > ("brandings", prepareRequest)); }
public List <Payment> Payments(PageParameters?pageParameters = null, SortingParameters?sortingParameters = null) { Action <RestRequest> prepareRequest = (RestRequest request) => { AddPagingParameters(pageParameters, request); AddSortingParameters(sortingParameters, request); }; return(CallEndpoint <List <Payment> > ("payments", prepareRequest)); }
protected void AddPagingParameters(PageParameters?pageParameters, RestRequest request) { if (pageParameters == null) { return; } request.AddParameter("page", pageParameters.Value.Page); request.AddParameter("page_size", pageParameters.Value.PageSize); }
void anim_CurrentTimeInvalidated(object sender, EventArgs e) { PageParameters?parameters = ComputePage(this, CornerPoint, origin); _cornerPoint = CornerPoint; if (parameters != null) { ApplyParameters(parameters.Value); } }
private void CornerPointRefreshed() { PageParameters?parameters = ComputePage(this, CornerPoint, origin); _cornerPoint = CornerPoint; if (parameters != null) { ApplyParameters(parameters.Value); } }
void anim_CurrentTimeInvalidated(object sender, EventArgs e) { //Application.Current.MainWindow.Title += "I"; PageParameters?parameters = ComputePage(this, CornerPoint, origin); _cornerPoint = CornerPoint; if (parameters != null) { ApplyParameters(parameters.Value); } }
public void MoveGrabPoint(UIElement source, Point p) { if ((Status == PageStatus.DropAnimation) || (Status == PageStatus.TurnAnimation) || (Status == PageStatus.None)) { return; } PageParameters?parameters = ComputePage(source, p, origin); _cornerPoint = p; if (parameters != null) { ApplyParameters(parameters.Value); } }
private void OnMouseMove(object sender, MouseEventArgs args) { UIElement source = sender as UIElement; Point p = args.GetPosition(source); DropPage(ComputeAnimationDuration(source, p, origin)); if ((Status == PageStatus.DropAnimation) || (Status == PageStatus.TurnAnimation)) { return; } //Application.Current.MainWindow.Title += "M"; if (!(sender as UIElement).IsMouseCaptured) { CornerOrigin?tmp = GetCorner(source, p); if (tmp.HasValue) { origin = tmp.Value; } else { //if (Status == PageStatus.DraggingWithoutCapture) //{ DropPage(ComputeAnimationDuration(source, p, origin)); //} return; } Status = PageStatus.DraggingWithoutCapture; } PageParameters?parameters = ComputePage(source, p, origin); _cornerPoint = p; if (parameters != null) { ApplyParameters(parameters.Value); } }
public List <AclResource> AclResources(AccountType accountType = AccountType.Any, PageParameters?pageParameters = null) { Action <RestRequest> prepareRequest = (RestRequest request) => { AddPagingParameters(pageParameters, request); if (accountType != AccountType.Any) { request.AddParameter("account_type", accountType.GetName()); } }; return(CallEndpoint <List <AclResource> > ("acl-resources", prepareRequest)); }