Skip to content

Instantly share code, notes, and snippets.

View RoLYroLLs's full-sized avatar
🎯
Focusing

RoLY roLLs RoLYroLLs

🎯
Focusing
View GitHub Profile
@RoLYroLLs
RoLYroLLs / Elgato Striplight Example.txt
Last active December 3, 2021 01:19
Streamer.Bot - Elgato Striplight Example
TlM0RR+LCAAAAAAABAC9Wmtv4krS/v5K+x/QSCudVzvOtu/2kc6HQAIYEpJAsMGb/dDubhsPDfZiLjGr/e9bbXMzIXNmMrMTKQl0t6urnnrq0rb//Zf/q9U+rdkii5P5p99r8udiYI5nDL59uuURXia1wXIRpzyOJsva7SuepZx9KtdhsoTrMlj6D/G9Vvt3+Q+mYioEKIpsyGaoSQYxsKTpBpGsQFYli2GVGcjSTQOVsoqL/rViK7HxfMX5cZTNccCZkLdcrNhx/Bu1LNZGi2SVisV3YkE8j07mMN/gPOuvBAAh5tnJFgs8p8nsujDz7SxJ5mS1WLD58u3cG2gq8BRL1pivSgPmS7aoOY81TOmCZVktCWuFIUclTzDFONCZYQGcqiwDppYhWRaypFDVVRNZisawdXbhhhXSfq+hK1SdWeapUEFGyK5OHABrJPMwjlYLXGBwptCcsldYpB5H//P5fXMXsXBkb+e2OL0uzW1k6zdyyYLNLuFaBU5GV7JyJV/Jn2v7j8pFzHQt1JmuGRKzsAnAsVAKVE2TmG0whGSDUIV8N2aK+gOQad8GWYUh9YVQaS4Y8tfab7IEXvv/i+bKzLaQZocS01XgCbUtKdA0RdIQ1i3LIlaA1V9MEfMjFAkOBv8IR5BgB7oMlB4ghYZUwmpAJE2mlmRjiCU9RJpm2gQx7fuB+iFeWB/gxQAvd0Jrv6H3WYE0Yto6CSVqMUPSTIogCKgKf2yLaYioSvj9QfBjrJCVj9AiO9j7P6KFRmVLtQmVAsYgxSJLliyTaJJtqIpMA40SrP1aWsjflGL3FbHL8rIQNiZ4HgFDfmskaX7OCsoyAiVzV9s+nc1OGUuvebxml4FcsJBB5SPsrMQVk43fX148UD3ZZC8v9zFZJFkSLq96t88vL80FKLl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LpL84IDTta5A6NwIvHUBriZOIb2tCGc/oNt6cqvmH2uyK882ViPf8MoJbHnKo9ZTXinox2fr58XEGOqeH7PFxENNtmqXh7tPw5uHxsb0F7Q7pdvX4uDegROmqrrmPj+uMplsRk09M
public IEnumerable<object> Pages(int current, int pageCount) {
List<object> pages = new List<object>();
var delta = 7;
if (pageCount > 7) {
delta = current > 4 && current < pageCount - 3 ? 2 : 4;
}
var startIndex = (int)Math.Round(current - delta / (double)2);
var endIndex = (int)Math.Round(current + delta / (double)2);
@RoLYroLLs
RoLYroLLs / DeviceConstant.swift
Created December 31, 2019 19:03
A list of all Apple device names easily accessible through enums. particularly useful for PreviewProvider in Swift
//
// DeviceConstants.swift
// SampleApp
//
// Created by RoLY roLLs on 12/31/19.
// Copyright © 2019 RoLYroLLs Enterprises, LLC. All rights reserved.
//
/// Taken from https://developer.apple.com/documentation/swiftui/securefield/3289399-previewdevice
/*
* bootstrap-session-timeout
* www.orangehilldev.com
*
* Copyright (c) 2014 Vedran Opacic
* Licensed under the MIT license.
*/
(function($) {
/*jshint multistr: true */
using System;
using System.Web.Mvc;
using Newtonsoft.Json;
public class JsonNetResult : JsonResult {
public JsonSerializerSettings SerializerSettings { get; set; }
public Formatting Formatting { get; set; }
public JsonNetResult(object data) {
this.JsonRequestBehavior = JsonRequestBehavior.DenyGet;
/*
CASE
- Order Selection, required
** Only 1 option can be chosen
- Patient, required
** I am going to make this into a separate class so user does not have to enter same patient info for multiple cases
@RoLYroLLs
RoLYroLLs / ClaimsAuthorizationAttribute.cs
Created February 12, 2018 22:53
Custom MVC AuthorizationAttribute for Role Claims
using System;
using System.Collections.Generic;
using System.Linq;
using System.Runtime.Caching;
using System.Security.Principal;
using System.Web;
using System.Web.Mvc;
[AttributeUsage(AttributeTargets.Method | AttributeTargets.Class, Inherited = true, AllowMultiple = true)]
public class ClaimsAuthorizationAttribute : AuthorizeAttribute {
@RoLYroLLs
RoLYroLLs / AuditTrailGenerator.sql
Created February 7, 2017 21:08
TSQL Audit Trail Generator with Triggers and Views
-- =============================================
--
-- Modification of https://www.codeproject.com/articles/21068/audit-trail-generator-for-microsoft-sql
--
-- Author: Rolando Liriano
-- Create date: 2017/02/03
-- Description: Creates an audit trail table along with triggers and views for a specified table
-- @TableName required - Name of the table to audit
-- @PrimaryKey required - Name of the primary key in table
-- @TableSchema optional - Current schema of the table
@RoLYroLLs
RoLYroLLs / .gitignore
Created September 7, 2014 01:02 — forked from adamgit/.gitignore
#########################
# .gitignore file for Xcode4 and Xcode5 Source projects
#
# Apple bugs, waiting for Apple to fix/respond:
#
# 15564624 - what does the xccheckout file in Xcode5 do? Where's the documentation?
#
# Version 2.1
# For latest version, see: http://stackoverflow.com/questions/49478/git-ignore-file-for-xcode-projects
#