text
stringlengths
9
39.2M
dir
stringlengths
26
295
lang
stringclasses
185 values
created_date
timestamp[us]
updated_date
timestamp[us]
repo_name
stringlengths
1
97
repo_full_name
stringlengths
7
106
star
int64
1k
183k
len_tokens
int64
1
13.8M
```xml import { Sensor } from '../../entities/sensor'; const mockMqttClient = { on: jest.fn(), publish: jest.fn(), subscribe: jest.fn(), end: jest.fn(), }; import { ClusterService } from '../../cluster/cluster.service'; import { MqttService } from './mqtt.service'; import { Test, TestingModule } from '@nestjs/testing'; import { NestEmitterModule } from 'nest-emitter'; import { ConfigModule } from '../../config/config.module'; import { EntitiesModule } from '../../entities/entities.module'; import { EventEmitter } from 'events'; import { EntitiesService } from '../../entities/entities.service'; import { ConfigService } from '../../config/config.service'; import c from 'config'; import { MqttConfig } from './mqtt.config'; import { mocked } from 'ts-jest/utils'; import * as mqtt from 'async-mqtt'; import { BinarySensor } from '../../entities/binary-sensor'; import { DeviceTracker } from '../../entities/device-tracker'; import { Switch } from '../../entities/switch'; import { Camera } from '../../entities/camera'; import { Entity } from '../../entities/entity.dto'; import { ClusterModule } from '../../cluster/cluster.module'; jest.mock('async-mqtt', () => { return { connectAsync: jest.fn().mockReturnValue(mockMqttClient), }; }); const mockMqtt = mocked(mqtt, true); describe('MqttService', () => { let service: MqttService; let mockConfig: MqttConfig; const entitiesEmitter = new EventEmitter(); const mqttEmitter = new EventEmitter(); const entitiesService = { getAll: jest.fn().mockReturnValue([]), hasAuthorityOver: jest.fn().mockReturnValue(true), }; const clusterService = new EventEmitter(); const configService = { get: jest.fn().mockImplementation((key: string) => { return key === 'mqtt' ? mockConfig : c.get(key); }), }; beforeEach(async () => { jest.clearAllMocks(); entitiesEmitter.removeAllListeners(); clusterService.removeAllListeners(); mqttEmitter.removeAllListeners(); mockMqttClient.on.mockImplementation((event, callback) => { mqttEmitter.on(event, callback); }); mockConfig = new MqttConfig(); const module: TestingModule = await Test.createTestingModule({ imports: [ NestEmitterModule.forRoot(entitiesEmitter), ConfigModule, EntitiesModule, ClusterModule, ], providers: [MqttService], }) .overrideProvider(EntitiesService) .useValue(entitiesService) .overrideProvider(ConfigService) .useValue(configService) .overrideProvider(ClusterService) .useValue(clusterService) .compile(); service = module.get<MqttService>(MqttService); }); it('should subscribe to entity events on init', async () => { const emitterOnSpy = jest.spyOn(entitiesEmitter, 'on'); await service.onModuleInit(); expect(emitterOnSpy).toHaveBeenCalledWith( 'entityUpdate', expect.any(Function) ); }); it('should connect to MQTT on init', async () => { await service.onModuleInit(); expect(mockMqtt.connectAsync).toHaveBeenCalledWith( expect.any(String), expect.any(Object), false ); }); it('should refresh entities on broker reconnect', async () => { const spy = jest.spyOn(service, 'refreshEntities'); await service.onModuleInit(); mqttEmitter.emit('connect'); expect(spy).toHaveBeenCalledTimes(1); }); it('should refresh entities after leader was elected', async () => { const spy = jest.spyOn(service, 'refreshEntities'); await service.onModuleInit(); clusterService.emit('elected'); expect(spy).toHaveBeenCalledTimes(1); }); it.each([ ['sensor', new Sensor('test', 'Test')], ['binary-sensor', new BinarySensor('test', 'Test')], ['device-tracker', new DeviceTracker('test', 'Test')], ['switch', new Switch('test', 'Test')], ['camera', new Camera('test', 'Test')], ])( 'should post %s entity update messages', async (entityTopic: string, entity: Entity) => { const diff = [ { newValue: 'new-state', oldValue: 'old-state', path: '/state', }, ]; const hasAuthority = true; await service.onModuleInit(); entitiesEmitter.emit('entityUpdate', entity, diff, hasAuthority); expect(mockMqttClient.publish).toHaveBeenCalledWith( `room-assistant/entity/test-instance/${entityTopic}/${entity.id}`, JSON.stringify({ entity, diff, hasAuthority }), expect.any(Object) ); } ); it.each([ ['sensor', new Sensor('test', 'Test')], ['binary-sensor', new BinarySensor('test', 'Test')], ['device-tracker', new DeviceTracker('test', 'Test')], ['switch', new Switch('test', 'Test')], ['camera', new Camera('test', 'Test')], ])( 'should post %s entity refresh messages', async (entityTopic: string, entity: Entity) => { entitiesService.getAll.mockReturnValue([entity]); await service.onModuleInit(); service.refreshEntities(); expect(mockMqttClient.publish).toHaveBeenCalledWith( `room-assistant/entity/test-instance/${entityTopic}/${entity.id}`, JSON.stringify({ entity, hasAuthority: true }), expect.any(Object) ); } ); it('should use the configured base topic', async () => { mockConfig.baseTopic = 'my-new-topic'; await service.onModuleInit(); entitiesEmitter.emit('entityUpdate', new Sensor('test', 'Test'), [], true); expect(mockMqttClient.publish).toHaveBeenCalledWith( 'my-new-topic/test-instance/sensor/test', expect.any(String), expect.any(Object) ); }); it('should pass the configured retain setting', async () => { mockConfig.retain = true; await service.onModuleInit(); entitiesEmitter.emit('entityUpdate', new Sensor('test', 'Test'), [], true); expect(mockMqttClient.publish).toHaveBeenCalledWith( expect.any(String), expect.any(String), expect.objectContaining({ retain: true, }) ); }); it('should pass the configured qos setting', async () => { mockConfig.qos = 2; await service.onModuleInit(); entitiesEmitter.emit('entityUpdate', new Sensor('test', 'Test'), [], true); expect(mockMqttClient.publish).toHaveBeenCalledWith( expect.any(String), expect.any(String), expect.objectContaining({ qos: 2, }) ); }); }); ```
/content/code_sandbox/src/integrations/mqtt/mqtt.service.spec.ts
xml
2016-08-18T18:50:21
2024-08-12T16:12:05
room-assistant
mKeRix/room-assistant
1,255
1,423
```xml <?xml version="1.0" encoding="UTF-8"?> <!-- or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file path_to_url Unless required by applicable law or agreed to in writing, "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY specific language governing permissions and limitations --> <!DOCTYPE concept PUBLIC "-//OASIS//DTD DITA Concept//EN" "concept.dtd"> <concept id="RETRY_FAILED_QUERIES" rev="2.10.0 IMPALA-3200"> <title>RETRY_FAILED_QUERIES Query Option</title> <titlealts audience="PDF"> <navtitle>RETRY FAILED QUERIES</navtitle> </titlealts> <prolog> <metadata> <data name="Category" value="Impala"/> <data name="Category" value="Impala Query Options"/> <data name="Category" value="Querying"/> <data name="Category" value="Developers"/> <data name="Category" value="Administrators"/> </metadata> </prolog> <conbody> <p>Use the <codeph>RETRY_FAILED_QUERIES</codeph> query option to control whether or not queries are transparently retried on cluster membership changes. </p> <p>Cluster membership changes typically occur when an impalad crashes, or if the node is blacklisted by the Impala Coordinator. If a SELECT query fails due to a cluster membership change, the Coordinator will cancel and unregister the running query and then launch a retry of the query. For example, if one of the executor nodes fails during query execution, the query fails but is transparently re-executed, either with the executor node immediately replaced, or with a temporarily reduced number of executor nodes. This feature supports retrying the entire query and NOT the individual query fragments. INSERT and DDL queries will NOT be retried.</p> <p>Note that query retry will be skipped if the query has returned any results to the client. To avoid this, enable <codeph>Result Spooling</codeph> and set the <codeph>spool_all_results_for_retries</codeph> query option.</p> <p><b>Type:</b> <codeph>BOOLEAN</codeph></p> <p><b>Default:</b> <codeph>TRUE</codeph></p> <p><b>Added in:</b> <keyword keyref="impala40"/></p> <p><b>Related information:</b> <xref href="impala_transparent_query_retries.xml"/></p> </conbody> </concept> ```
/content/code_sandbox/docs/topics/impala_retry_failed_queries.xml
xml
2016-04-13T07:00:08
2024-08-16T10:10:44
impala
apache/impala
1,115
615
```xml <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "path_to_url"> <plist version="1.0"> <dict> <key>CFBundleDevelopmentRegion</key> <string>en</string> <key>CFBundleExecutable</key> <string>$(EXECUTABLE_NAME)</string> <key>CFBundleIdentifier</key> <string>$(PRODUCT_BUNDLE_IDENTIFIER)</string> <key>CFBundleInfoDictionaryVersion</key> <string>6.0</string> <key>CFBundleName</key> <string>$(PRODUCT_NAME)</string> <key>CFBundlePackageType</key> <string>APPL</string> <key>CFBundleShortVersionString</key> <string>1.0</string> <key>CFBundleSignature</key> <string>????</string> <key>CFBundleVersion</key> <string>1</string> <key>LSRequiresIPhoneOS</key> <true/> <key>UILaunchStoryboardName</key> <string>LaunchScreen</string> <key>UIMainStoryboardFile</key> <string>Main</string> <key>UIRequiredDeviceCapabilities</key> <array> <string>armv7</string> </array> <key>UISupportedInterfaceOrientations</key> <array> <string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationLandscapeLeft</string> <string>UIInterfaceOrientationLandscapeRight</string> </array> <key>UISupportedInterfaceOrientations~ipad</key> <array> <string>UIInterfaceOrientationPortrait</string> <string>UIInterfaceOrientationPortraitUpsideDown</string> <string>UIInterfaceOrientationLandscapeLeft</string> <string>UIInterfaceOrientationLandscapeRight</string> </array> <key>NSAppTransportSecurity</key> <dict> <key>NSAllowsArbitraryLoads</key> <true/> </dict> </dict> </plist> ```
/content/code_sandbox/Project 07 - PokedexGo/PokedexGo/Info.plist
xml
2016-02-14T20:14:21
2024-08-15T20:49:08
Swift-30-Projects
soapyigu/Swift-30-Projects
8,036
473
```xml <!-- ~ contributor license agreements. See the NOTICE file distributed with ~ this work for additional information regarding copyright ownership. ~ ~ path_to_url ~ ~ Unless required by applicable law or agreed to in writing, software ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --> <dataset> <metadata> <column name="implementation_info_id" /> <column name="implementation_info_name" /> <column name="integer_value" /> <column name="character_value" /> <column name="comments" /> </metadata> </dataset> ```
/content/code_sandbox/test/e2e/sql/src/test/resources/cases/dql/dataset/empty_storage_units/postgresql/select_postgresql_information_schema_sql_implementation_info.xml
xml
2016-01-18T12:49:26
2024-08-16T15:48:11
shardingsphere
apache/shardingsphere
19,707
132
```xml import { faker } from "@faker-js/faker"; import { CollectionPermission } from "@shared/types"; import { buildUser, buildTeam, buildCollection } from "@server/test/factories"; import UserMembership from "./UserMembership"; beforeAll(() => { jest.useFakeTimers().setSystemTime(new Date("2018-01-02T00:00:00.000Z")); }); afterAll(() => { jest.useRealTimers(); }); describe("user model", () => { describe("create", () => { it("should not allow URLs in name", async () => { await expect( buildUser({ name: "www.google.com", }) ).rejects.toThrow(); await expect( buildUser({ name: "My name path_to_url", }) ).rejects.toThrow(); await expect( buildUser({ name: "wwwww", }) ).resolves.toBeDefined(); }); }); describe("destroy", () => { it("should clear PII", async () => { const user = await buildUser(); await user.destroy(); expect(user.email).toBe(null); expect(user.name).toBe("Unknown"); }); }); describe("getJwtToken", () => { it("should set JWT secret", async () => { const user = await buildUser(); expect(user.getJwtToken()).toBeTruthy(); }); }); describe("availableTeams", () => { it("should return teams where another user with the same email exists", async () => { const email = faker.internet.email().toLowerCase(); const user = await buildUser({ email, }); const anotherUser = await buildUser({ email }); const response = await user.availableTeams(); expect(response.length).toEqual(2); expect(response[0].id).toEqual(user.teamId); expect(response[1].id).toEqual(anotherUser.teamId); }); }); describe("collectionIds", () => { it("should return read_write collections", async () => { const team = await buildTeam(); const user = await buildUser({ teamId: team.id, }); const collection = await buildCollection({ teamId: team.id, permission: CollectionPermission.ReadWrite, }); const response = await user.collectionIds(); expect(response.length).toEqual(1); expect(response[0]).toEqual(collection.id); }); it("should return read collections", async () => { const team = await buildTeam(); const user = await buildUser({ teamId: team.id, }); const collection = await buildCollection({ teamId: team.id, permission: CollectionPermission.Read, }); const response = await user.collectionIds(); expect(response.length).toEqual(1); expect(response[0]).toEqual(collection.id); }); it("should not return private collections", async () => { const team = await buildTeam(); const user = await buildUser({ teamId: team.id, }); await buildCollection({ teamId: team.id, permission: null, }); const response = await user.collectionIds(); expect(response.length).toEqual(0); }); it("should not return private collection with membership", async () => { const team = await buildTeam(); const user = await buildUser({ teamId: team.id, }); const collection = await buildCollection({ teamId: team.id, permission: null, }); await UserMembership.create({ createdById: user.id, collectionId: collection.id, userId: user.id, permission: CollectionPermission.Read, }); const response = await user.collectionIds(); expect(response.length).toEqual(1); expect(response[0]).toEqual(collection.id); }); }); }); ```
/content/code_sandbox/server/models/User.test.ts
xml
2016-05-22T21:31:47
2024-08-16T19:57:22
outline
outline/outline
26,751
815
```xml // eslint-disable-next-line import/no-extraneous-dependencies import * as React from 'react'; export interface ProviderContextValueV2 { foo: string; } export const ProviderContext = React.createContext<ProviderContextValueV2>({ foo: 'foo' }); ```
/content/code_sandbox/packages/react-components/babel-preset-global-context/src/testing/fake_node_modules/ignored-context-v1.0.0/index.ts
xml
2016-06-06T15:03:44
2024-08-16T18:49:29
fluentui
microsoft/fluentui
18,221
57
```xml <manifest xmlns:android="path_to_url"> <application> <!-- path_to_url --> <provider android:name=".MailComposerFileProvider" android:authorities="${applicationId}.MailComposerFileProvider" android:exported="false" android:grantUriPermissions="true"> <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/mail_composer_provider_paths"/> </provider> </application> <queries> <intent> <!-- Required for sending mails if targeting API 30 --> <action android:name="android.intent.action.SENDTO" /> <data android:scheme="mailto" /> </intent> <intent> <action android:name="android.intent.action.SEND_MULTIPLE" /> <category android:name="android.intent.category.DEFAULT" /> <data android:mimeType="*/*" /> </intent> </queries> </manifest> ```
/content/code_sandbox/packages/expo-mail-composer/android/src/main/AndroidManifest.xml
xml
2016-08-15T17:14:25
2024-08-16T19:54:44
expo
expo/expo
32,004
194
```xml import React from "react"; import { colors } from "../styles"; import { stripe } from "../utils/animations"; import styled from "styled-components"; import styledTS from "styled-components-ts"; const ContentContainer = styled.div` position: relative; z-index: 3; color: ${colors.colorCoreDarkGray}; text-align: center; `; const Wrapper = styledTS<{ height?: string }>(styled.div)` position: relative; padding: 0px 30px; background: ${colors.bgMain}; width: 100%; height: ${(props) => (props.height ? props.height : "36px")}; box-shadow: inset 0 -2px 6px rgba(0, 0, 0, 0.05); a:hover { cursor: pointer; } > a { outline: none; top: 11px; right: 20px; position: absolute; font-size: 10px; color: ${colors.colorCoreGray}; } `; const Progress = styledTS<{ color?: string }>(styled.div)` position: absolute; background: ${(props) => props.color}; left: 0; top: 0; bottom: 0; background-image: linear-gradient( 45deg, rgba(255, 255, 255, 0.1) 25%, transparent 25%, transparent 50%, rgba(255, 255, 255, 0.1) 50%, rgba(255, 255, 255, 0.1) 75%, transparent 75%, transparent ); background-size: 16px 16px; border-radius: 2px; transition: width 0.5s ease; animation: ${stripe} 1s linear infinite; `; const Container = styled.div` position: relative; display: flex; `; const Circle = styled.circle` fill: transparent; stroke: hsla(225, 20%, 92%, 0.9); stroke-linecap: round; `; const FilledCircle: any = styledTS<{ color?: string }>(styled(Circle))` stroke: ${(props) => props.color}; transform: rotate(-90deg); transform-origin: 50% 50%; transition: stroke-dashoffset 0.5s ease-out; `; export const Text = styledTS<{ color?: string }>(styled.div)` align-items: center; color: ${(props) => props.color}; display: flex; font-weight: bold; height: 100%; justify-content: center; left: 0; letter-spacing: 0.025em; margin-bottom: 1rem; position: absolute; right: 0; top: 0; width: 100%; `; type Props = { children?: React.ReactNode; close?: React.ReactNode; percentage: number; color?: string; height?: string; type?: string; strokeWidthNumber?: number; }; function ProgressBar({ percentage, children, close, color = "#dddeff", height, type, strokeWidthNumber, }: Props) { if (type === "circle") { const strokeWidth = strokeWidthNumber || 3; const radius = 100 / 2 - strokeWidth * 2; const circumference = radius * 2 * Math.PI; const offset = circumference - (percentage / 100) * circumference; return ( <Container> <svg aria-valuemax={100} aria-valuemin={0} aria-valuenow={percentage} height={height} role="progressbar" width={height} viewBox="0 0 100 100" version="1.1" xmlns="path_to_url" > <Circle cx="50" cy="50" r={radius} strokeWidth={strokeWidth} /> <FilledCircle color={color} cx="50" cy="50" data-testid="progress-bar-bar" r={radius} strokeDasharray={`${circumference} ${circumference}`} strokeDashoffset={offset} strokeWidth={strokeWidth} /> </svg> <Text color={color} data-testid="progress-bar-text"> {percentage}% </Text> </Container> ); } return ( <Wrapper height={height}> <Progress style={{ width: `${percentage}%` }} color={color} /> <ContentContainer>{children}</ContentContainer> {close} </Wrapper> ); } export default ProgressBar; ```
/content/code_sandbox/packages/erxes-ui/src/components/ProgressBar.tsx
xml
2016-11-11T06:54:50
2024-08-16T10:26:06
erxes
erxes/erxes
3,479
1,014
```xml import type { Template } from './index.js'; import { brightMix, colorSetToVariants } from '../color-set/index.js'; import Color from 'color'; import { source } from 'common-tags'; import { fromByteArray } from 'base64-js'; function stringToByteArray(str: string) { const bytes = []; for (let i = 0; i < str.length; i++) { bytes.push(str.charCodeAt(i)); } return new Uint8Array(bytes); } // Prior art: stayradiated/termcolors and chriskempson/base16-builder export function toData(hex: string): string { const code: [Uint8Array, Uint8Array] = [ new Uint8Array([ 0x62, 0x70, 0x6c, 0x69, 0x73, 0x74, 0x30, 0x30, 0xd4, 0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x15, 0x16, 0x58, 0x24, 0x76, 0x65, 0x72, 0x73, 0x69, 0x6f, 0x6e, 0x58, 0x24, 0x6f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x73, 0x59, 0x24, 0x61, 0x72, 0x63, 0x68, 0x69, 0x76, 0x65, 0x72, 0x54, 0x24, 0x74, 0x6f, 0x70, 0x12, 0x00, 0x01, 0x86, 0xa0, 0xa3, 0x07, 0x08, 0x0f, 0x55, 0x24, 0x6e, 0x75, 0x6c, 0x6c, 0xd3, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x55, 0x4e, 0x53, 0x52, 0x47, 0x42, 0x5c, 0x4e, 0x53, 0x43, 0x6f, 0x6c, 0x6f, 0x72, 0x53, 0x70, 0x61, 0x63, 0x65, 0x56, 0x24, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x4f, 0x10, 0x27, ]), new Uint8Array([ 0x00, 0x10, 0x01, 0x80, 0x02, 0xd2, 0x10, 0x11, 0x12, 0x13, 0x5a, 0x24, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x6e, 0x61, 0x6d, 0x65, 0x58, 0x24, 0x63, 0x6c, 0x61, 0x73, 0x73, 0x65, 0x73, 0x57, 0x4e, 0x53, 0x43, 0x6f, 0x6c, 0x6f, 0x72, 0xa2, 0x12, 0x14, 0x58, 0x4e, 0x53, 0x4f, 0x62, 0x6a, 0x65, 0x63, 0x74, 0x5f, 0x10, 0x0f, 0x4e, 0x53, 0x4b, 0x65, 0x79, 0x65, 0x64, 0x41, 0x72, 0x63, 0x68, 0x69, 0x76, 0x65, 0x72, 0xd1, 0x17, 0x18, 0x54, 0x72, 0x6f, 0x6f, 0x74, 0x80, 0x01, 0x08, 0x11, 0x1a, 0x23, 0x2d, 0x32, 0x37, 0x3b, 0x41, 0x48, 0x4e, 0x5b, 0x62, 0x8c, 0x8e, 0x90, 0x95, 0xa0, 0xa9, 0xb1, 0xb4, 0xbd, 0xcf, 0xd2, 0xd7, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x01, 0x01, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x19, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0xd9, ]), ]; const srgb = Color(hex) .rgb() .array() .map((channel) => (channel / 255).toFixed(10)) .join(' '); return fromByteArray( new Uint8Array([...code[0], ...stringToByteArray(srgb), ...code[1]]), ); } const template: Template = { name: 'Terminal', render: async function* (colorSet) { const variants = colorSetToVariants(colorSet); for (const { title, colors, isDark } of variants) { yield { path: `${title.human}.terminal`, content: source` <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "path_to_url"> <plist version="1.0"> <dict> <key>name</key> <string>${title.human}</string> <key>type</key> <string>Window Settings</string> <key>BackgroundColor</key> <data>${toData(colors.shade0)}</data> <key>TextColor</key> <data>${toData(colors.shade6)}</data> <key>BoldTextColor</key> <data>${toData(colors.shade7)}</data> <key>CursorColor</key> <data>${toData(colors.accent6)}</data> <key>SelectionColor</key> <data>${toData(colors.accent7)}</data> <key>ANSIBlackColor</key> <data>${ isDark ? toData(colors.shade0) : toData(colors.shade7) }</data> <key>ANSIRedColor</key> <data>${toData(colors.accent0)}</data> <key>ANSIGreenColor</key> <data>${toData(colors.accent3)}</data> <key>ANSIYellowColor</key> <data>${toData(colors.accent2)}</data> <key>ANSIBlueColor</key> <data>${toData(colors.accent5)}</data> <key>ANSIMagentaColor</key> <data>${toData(colors.accent7)}</data> <key>ANSICyanColor</key> <data>${toData(colors.accent4)}</data> <key>ANSIWhiteColor</key> <data>${ isDark ? toData(colors.shade6) : toData(colors.shade1) }</data> <key>ANSIBrightBlackColor</key> <data>${ isDark ? toData(colors.shade1) : toData(colors.shade6) }</data> <key>ANSIBrightRedColor</key> <data>${toData(brightMix(colors, 'accent0', isDark))}</data> <key>ANSIBrightGreenColor</key> <data>${toData(brightMix(colors, 'accent3', isDark))}</data> <key>ANSIBrightYellowColor</key> <data>${toData(brightMix(colors, 'accent2', isDark))}</data> <key>ANSIBrightBlueColor</key> <data>${toData(brightMix(colors, 'accent5', isDark))}</data> <key>ANSIBrightMagentaColor</key> <data>${toData(brightMix(colors, 'accent7', isDark))}</data> <key>ANSIBrightCyanColor</key> <data>${toData(brightMix(colors, 'accent4', isDark))}</data> <key>ANSIBrightWhiteColor</key> <data>${ isDark ? toData(colors.shade7) : toData(colors.shade0) }</data> </dict> </plist> `, }; } }, renderInstructions: (paths, colorSet) => source` 1. Launch Terminal.app and open the preferences (\`cmd\`-\`,\`) 2. Click Profiles > (...) icon > Import... 3. Choose the generated ${paths.length > 1 ? 'files' : 'file'} (${paths .map((p) => `\`${p}\``) .join(' / ')}) 4. Select the imported theme (${colorSetToVariants(colorSet) .map((v) => v.title.human) .map((name) => `"${name}"`) .join(' or ')}) from the profile picker `, }; export default template; ```
/content/code_sandbox/cli/src/template/terminal.ts
xml
2016-11-21T13:42:28
2024-08-16T10:14:09
themer
themerdev/themer
5,463
2,412
```xml <?xml version="1.0" encoding="UTF-8"?> <project xmlns="path_to_url" xmlns:xsi="path_to_url" xsi:schemaLocation="path_to_url path_to_url"> <modelVersion>4.0.0</modelVersion> <parent> <groupId>io.camunda</groupId> <artifactId>zeebe-parent</artifactId> <version>8.6.0-SNAPSHOT</version> <relativePath>../../parent/pom.xml</relativePath> </parent> <artifactId>zeebe-db</artifactId> <packaging>jar</packaging> <name>Zeebe DB</name> <dependencies> <!-- This dependency is for EnumValue --> <dependency> <groupId>io.camunda</groupId> <artifactId>zeebe-protocol</artifactId> </dependency> <dependency> <groupId>io.camunda</groupId> <artifactId>zeebe-util</artifactId> </dependency> <dependency> <groupId>io.camunda</groupId> <artifactId>zeebe-snapshots</artifactId> </dependency> <dependency> <groupId>org.agrona</groupId> <artifactId>agrona</artifactId> </dependency> <dependency> <groupId>org.rocksdb</groupId> <artifactId>rocksdbjni</artifactId> </dependency> <dependency> <groupId>org.slf4j</groupId> <artifactId>slf4j-api</artifactId> </dependency> <dependency> <groupId>junit</groupId> <artifactId>junit</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.junit.jupiter</groupId> <artifactId>junit-jupiter-api</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.assertj</groupId> <artifactId>assertj-core</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>org.mockito</groupId> <artifactId>mockito-core</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>net.jqwik</groupId> <artifactId>jqwik-api</artifactId> <scope>test</scope> </dependency> <dependency> <groupId>io.prometheus</groupId> <artifactId>simpleclient</artifactId> </dependency> <dependency> <groupId>org.junit.jupiter</groupId> <artifactId>junit-jupiter-params</artifactId> <scope>test</scope> </dependency> </dependencies> </project> ```
/content/code_sandbox/zeebe/zb-db/pom.xml
xml
2016-03-20T03:38:04
2024-08-16T19:59:58
camunda
camunda/camunda
3,172
612
```xml <RelativeLayout xmlns:android="path_to_url" xmlns:tools="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent" android:paddingLeft="@dimen/activity_horizontal_margin" android:paddingRight="@dimen/activity_horizontal_margin" android:paddingTop="@dimen/activity_vertical_margin" android:paddingBottom="@dimen/activity_vertical_margin" tools:context=".MainActivity"> <TextView android:text="@string/first" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textSize="28sp" android:layout_centerVertical="true" android:layout_centerHorizontal="true" android:id="@+id/textView" /> <Button android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="Button" android:id="@+id/button" android:layout_below="@+id/textView" android:layout_centerHorizontal="true" /> </RelativeLayout> ```
/content/code_sandbox/Android/Intents/app/src/main/res/layout/activity_main.xml
xml
2016-05-02T05:43:21
2024-08-16T06:51:39
journaldev
WebJournal/journaldev
1,314
213
```xml import { Block } from "payload/types"; import { backgroundColor } from "../../fields/backgroundColor"; export const MediaBlock: Block = { slug: "mediaBlock", fields: [ { type: "row", fields: [ backgroundColor({ overrides: { name: "mediaBlockBackgroundColor" } }), { name: "position", type: "select", defaultValue: "default", options: [ { label: "Default", value: "default", }, { label: "Fullscreen", value: "fullscreen", }, ], }, ], }, { name: "media", type: "upload", relationTo: "media", required: true, }, { name: "caption", type: "richText", admin: { elements: ["link"], }, }, ], }; ```
/content/code_sandbox/examples/cms-payload/payload/blocks/Media/index.ts
xml
2016-10-05T23:32:51
2024-08-16T19:44:30
next.js
vercel/next.js
124,056
189
```xml <?xml version="1.0" encoding="utf-8"?> <android.support.design.widget.CoordinatorLayout xmlns:android="path_to_url" xmlns:app="path_to_url" xmlns:tools="path_to_url" android:id="@+id/coordinator_layout" android:layout_width="match_parent" android:layout_height="match_parent" tools:context=".ui.activities.CollectionActivity"> <android.support.design.widget.AppBarLayout android:id="@+id/app_bar" android:layout_width="match_parent" android:layout_height="wrap_content" android:theme="@style/AppTheme.AppBarOverlay" app:elevation="0dp"> <android.support.v7.widget.Toolbar android:id="@+id/toolbar" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingStart="-16dp" android:paddingEnd="16dp" android:clipChildren="false" android:clipToPadding="false" app:contentInsetStart="0dp" app:layout_collapseMode="pin" android:fitsSystemWindows="true" app:popupTheme="@style/AppTheme.PopupOverlay"> <LinearLayout android:layout_width="match_parent" android:layout_height="match_parent"> <ImageView android:id="@+id/btn_return" android:layout_width="48dp" android:layout_height="@dimen/tool_bar_height" android:background="@drawable/bg_button" android:padding="16dp" android:scaleType="fitXY" /> <TextView android:id="@+id/tv_title" android:visibility="gone" android:layout_width="0dp" android:layout_height="match_parent" android:layout_weight="1" android:gravity="center_vertical" android:text="" android:textAppearance="@style/ActionBar.Title" /> <android.support.v7.widget.AppCompatSpinner android:id="@+id/spinner_source" android:layout_width="0dp" android:layout_height="match_parent" android:layout_weight="1" android:gravity="left" android:popupBackground="@color/white" android:theme="@style/source_spinner"/> <ImageView android:id="@+id/btn_update_all" android:layout_width="@dimen/tool_bar_height" android:layout_height="@dimen/tool_bar_height" android:padding="14dp" android:background="@drawable/bg_button" app:srcCompat="@drawable/ic_update_white"/> </LinearLayout> </android.support.v7.widget.Toolbar> </android.support.design.widget.AppBarLayout> <RelativeLayout android:layout_width="match_parent" android:layout_height="match_parent" app:layout_behavior="@string/appbar_scrolling_view_behavior"> <ml.puredark.hviewer.ui.customs.ExTabLayout android:id="@+id/tab_layout" android:layout_width="match_parent" android:layout_height="44dp" android:background="@color/colorPrimary" android:paddingLeft="@dimen/half_padding" android:paddingRight="@dimen/half_padding" app:tabBackground="@color/transparent" app:tabIndicatorColor="@color/white" app:tabIndicatorHeight="3dp" app:tabMode="scrollable" app:tabMyTextColor="@color/white" app:tabTitleArray="ACG,Booru,," /> <ml.puredark.hviewer.ui.customs.ExViewPager android:id="@+id/view_pager" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_below="@id/tab_layout" app:pagerCurrItem="0" app:pagerLayout1="@layout/view_market_site_list" /> <View android:id="@+id/shadowDown" android:layout_width="match_parent" android:layout_height="4dp" android:layout_below="@id/tab_layout" android:background="@drawable/shadow_bottom" /> <com.gc.materialdesign.views.ProgressBarCircularIndeterminate android:id="@+id/progress_bar" android:layout_width="60dp" android:layout_height="60dp" android:layout_centerInParent="true" android:background="@color/colorAccentDark"/> </RelativeLayout> </android.support.design.widget.CoordinatorLayout> ```
/content/code_sandbox/app/src/main/res/layout/activity_market.xml
xml
2016-08-08T13:25:41
2024-08-15T07:21:04
H-Viewer
PureDark/H-Viewer
1,738
951
```xml import * as Blockly from "blockly"; Blockly.defineBlocksWithJsonArray([ // BEGIN JSON EXTRACT // Block for text value { "type": "text", "message0": "%1", "args0": [{ "type": "field_string", "name": "TEXT", "text": "" }], "output": "String", "outputShape": new Blockly.zelos.ConstantProvider().SHAPES.ROUND, "style": "field_blocks", "helpUrl": "%{BKY_TEXT_TEXT_HELPURL}", "tooltip": "%{BKY_TEXT_TEXT_TOOLTIP}", "extensions": [ //"text_quotes", "parent_tooltip_when_inline" ] } ]); ```
/content/code_sandbox/pxtblocks/plugins/text/text.ts
xml
2016-01-24T19:35:52
2024-08-16T16:39:39
pxt
microsoft/pxt
2,069
158
```xml import Component from '../../dom_components/model/Component'; import { CommandObject } from './CommandAbstract'; export default { run(ed, snd, opts = {}) { if (!ed.Canvas.hasFocus() && !opts.force) return; const toSelect: Component[] = []; ed.getSelectedAll().forEach((component) => { let next = component.parent(); // Recurse through the parent() chain until a selectable parent is found while (next && !next.get('selectable')) { next = next.parent(); } next && toSelect.push(next); }); toSelect.length && ed.select(toSelect); }, } as CommandObject; ```
/content/code_sandbox/src/commands/view/ComponentExit.ts
xml
2016-01-22T00:23:19
2024-08-16T11:20:59
grapesjs
GrapesJS/grapesjs
21,687
140
```xml <vector xmlns:android="path_to_url" android:width="24dp" android:height="24dp" android:viewportWidth="24" android:viewportHeight="24"> <path android:fillColor="#000000" android:fillType="evenOdd" android:pathData="m9.293,3.293c0.188,-0.188 0.442,-0.293 0.707,-0.293h4c0.265,0 0.52,0.105 0.707,0.293 0.188,0.188 0.293,0.442 0.293,0.707v1h-6v-1c0,-0.265 0.105,-0.52 0.293,-0.707zM7,5v-1c0,-0.796 0.316,-1.559 0.879,-2.121s1.326,-0.879 2.121,-0.879h4c0.796,0 1.559,0.316 2.121,0.879s0.879,1.326 0.879,2.121v1h2,2c0.552,0 1,0.448 1,1s-0.448,1 -1,1h-1v13c0,0.796 -0.316,1.559 -0.879,2.121s-1.326,0.879 -2.121,0.879h-10c-0.796,0 -1.559,-0.316 -2.121,-0.879s-0.879,-1.326 -0.879,-2.121v-13h-1c-0.552,0 -1,-0.448 -1,-1s0.448,-1 1,-1h2zM6,7v13c0,0.265 0.105,0.52 0.293,0.707 0.188,0.188 0.442,0.293 0.707,0.293h10c0.265,0 0.52,-0.105 0.707,-0.293s0.293,-0.442 0.293,-0.707v-13zM10,10c0.552,0 1,0.448 1,1v6c0,0.552 -0.448,1 -1,1 -0.552,0 -1,-0.448 -1,-1v-6c0,-0.552 0.448,-1 1,-1zM15,17v-6c0,-0.552 -0.448,-1 -1,-1s-1,0.448 -1,1v6c0,0.552 0.448,1 1,1s1,-0.448 1,-1z" /> </vector> ```
/content/code_sandbox/app/src/main/res/drawable/ic_trash.xml
xml
2016-05-04T11:46:20
2024-08-15T16:29:10
android
meganz/android
1,537
654
```xml import * as React from 'react'; import { FUI_FRAME_EVENT } from './useIFrameFocusDispatch'; /** * Set a listener for a custom event emmited by the useIFrameFocusDispatch to execute the callback */ export const useIFrameListener = ( enableFrameFocusDispatch: boolean, callback: (e: Event) => void, targetDocument: Document, ) => { const listener = React.useCallback( (e: Event) => { if (callback) { callback(e); } }, [callback], ); React.useEffect(() => { if (enableFrameFocusDispatch) { targetDocument?.addEventListener(FUI_FRAME_EVENT, listener); } return () => { targetDocument?.removeEventListener(FUI_FRAME_EVENT, listener); }; }, [targetDocument, enableFrameFocusDispatch, listener]); }; ```
/content/code_sandbox/packages/fluentui/react-bindings/src/hooks/useIFrameListener.ts
xml
2016-06-06T15:03:44
2024-08-16T18:49:29
fluentui
microsoft/fluentui
18,221
185
```xml export * from "./from-promise" export * from "./array" export * from "./lazy-observable" export * from "./from-resource" export * from "./observable-stream" export * from "./create-view-model" export * from "./keep-alive" export * from "./queue-processor" export * from "./chunk-processor" export * from "./now" export * from "./utils" export * from "./expr" export * from "./create-transformer" export * from "./deepObserve" export { ObservableGroupMap } from "./ObservableGroupMap" export { computedFn } from "./computedFn" ```
/content/code_sandbox/src/mobx-utils.ts
xml
2016-08-07T20:37:49
2024-08-10T13:14:54
mobx-utils
mobxjs/mobx-utils
1,182
125
```xml <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "path_to_url"> <plist version="1.0"> <dict> <key>Advanscene_AutoDetectRomSaveType</key> <true/> <key>CheatDatabase_RecentFilePath</key> <array/> <key>CoreControl_EnableAutoFrameSkip</key> <true/> <key>CoreControl_FramesToSkipSetting</key> <integer>0</integer> <key>CoreControl_EnableCheats</key> <true/> <key>CoreControl_EnableSpeedLimit</key> <true/> <key>CoreControl_SpeedScalar</key> <real>1</real> <key>Debug_AppAppearanceMode</key> <integer>0</integer> <key>Debug_DisableMetal</key> <false/> <key>Debug_GDBStubEnableARM9</key> <false/> <key>Debug_GDBStubEnableARM7</key> <false/> <key>Debug_GDBStubPortARM9</key> <integer>20000</integer> <key>Debug_GDBStubPortARM7</key> <integer>20001</integer> <key>DisplayView_Deposterize</key> <false/> <key>DisplayView_FiltersPreferGPU</key> <true/> <key>DisplayView_Mode</key> <integer>2</integer> <key>DisplayView_OutputFilter</key> <integer>1</integer> <key>DisplayView_Rotation</key> <integer>0</integer> <key>DisplayView_DisplayMainVideoSource</key> <integer>1</integer> <key>DisplayView_DisplayTouchVideoSource</key> <integer>1</integer> <key>DisplayView_EnableHUD</key> <false/> <key>DisplayView_ShowStatusBar</key> <true/> <key>DisplayView_Size</key> <integer>100</integer> <key>DisplayView_UseBilinearOutput</key> <true/> <key>DisplayView_VideoFilter</key> <integer>0</integer> <key>DisplayViewCombo_Gap</key> <integer>0</integer> <key>DisplayViewCombo_Order</key> <integer>0</integer> <key>DisplayViewCombo_Orientation</key> <integer>0</integer> <key>Emulation_AdvancedBusLevelTiming</key> <true/> <key>Emulation_BIOSEmulateSWI</key> <true/> <key>Emulation_BIOSPatchDelayLoopSWI</key> <false/> <key>Emulation_CPUEmulationEngine</key> <integer>0</integer> <key>Emulation_EmulateEnsata</key> <false/> <key>Emulation_FirmwareBoot</key> <false/> <key>Emulation_MaxJITBlockSize</key> <integer>12</integer> <key>Emulation_RigorousTiming</key> <false/> <key>Emulation_StylusPressure</key> <integer>50</integer> <key>Emulation_UseDebugConsole</key> <false/> <key>Emulation_UseExternalBIOSImages</key> <false/> <key>Emulation_UseExternalFirmwareImage</key> <false/> <key>Emulation_UseGameSpecificHacks</key> <true/> <key>EmulationSlot1_DeviceType</key> <integer>1</integer> <key>FirmwareConfig_AddressSelection</key> <integer>0</integer> <key>FirmwareConfig_FirmwareMACAddress</key> <integer>0</integer> <key>FirmwareConfig_CustomMACAddress</key> <integer>0</integer> <key>FirmwareConfig_WFCUserID</key> <dict/> <key>FirmwareConfig_IPv4Address_AP1_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP1_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP1_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP1_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP1_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP1_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP1_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP1_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP1_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP1_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP1_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP1_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP1_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP1_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP1_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP1_4</key> <integer>0</integer> <key>FirmwareConfig_SubnetMask_AP1</key> <integer>24</integer> <key>FirmwareConfig_IPv4Address_AP2_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP2_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP2_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP2_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP2_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP2_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP2_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP2_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP2_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP2_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP2_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP2_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP2_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP2_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP2_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP2_4</key> <integer>0</integer> <key>FirmwareConfig_SubnetMask_AP2</key> <integer>24</integer> <key>FirmwareConfig_IPv4Address_AP3_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP3_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP3_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4Address_AP3_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP3_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP3_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP3_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4Gateway_AP3_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP3_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP3_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP3_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4PrimaryDNS_AP3_4</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP3_1</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP3_2</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP3_3</key> <integer>0</integer> <key>FirmwareConfig_IPv4SecondaryDNS_AP3_4</key> <integer>0</integer> <key>FirmwareConfig_SubnetMask_AP3</key> <integer>24</integer> <key>FirmwareConfig_Birthday</key> <date>2011-06-23T07:00:00Z</date> <key>FirmwareConfig_FavoriteColor</key> <integer>7</integer> <key>FirmwareConfig_Language</key> <integer>1</integer> <key>FirmwareConfig_Message</key> <string>DeSmuME makes you happy!</string> <key>FirmwareConfig_Nickname</key> <string>DeSmuME</string> <key>General_AppFirstTimeRun</key> <dict/> <key>General_AutoloadROMOption</key> <integer>10000</integer> <key>General_DisplayWindowRestorableStates</key> <array/> <key>General_DoNotAskMigrate</key> <false/> <key>General_ExecuteROMOnLoad</key> <true/> <key>General_StreamLoadRomData</key> <true/> <key>General_WillRestoreDisplayWindows</key> <true/> <key>HUD_ShowExecutionSpeed</key> <false/> <key>HUD_ShowVideoFPS</key> <true/> <key>HUD_ShowRender3DFPS</key> <false/> <key>HUD_ShowFrameIndex</key> <false/> <key>HUD_ShowLagFrameCount</key> <false/> <key>HUD_ShowCPULoadAverage</key> <false/> <key>HUD_ShowRTC</key> <false/> <key>HUD_ShowInput</key> <false/> <key>HUD_Color_ExecutionSpeed</key> <integer>4294967295</integer> <key>HUD_Color_VideoFPS</key> <integer>4294967295</integer> <key>HUD_Color_Render3DFPS</key> <integer>4294967295</integer> <key>HUD_Color_FrameIndex</key> <integer>4294967295</integer> <key>HUD_Color_LagFrameCount</key> <integer>4294967295</integer> <key>HUD_Color_CPULoadAverage</key> <integer>4294967295</integer> <key>HUD_Color_RTC</key> <integer>4294967295</integer> <key>HUD_Color_Input_PendingAndApplied</key> <integer>4294967295</integer> <key>HUD_Color_Input_AppliedOnly</key> <integer>4281348351</integer> <key>HUD_Color_Input_PendingOnly</key> <integer>4278239232</integer> <key>Input_AudioInputMode</key> <integer>1</integer> <key>Input_ControllerMappings</key> <dict> <key>Up</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>126</string> <key>elementName</key> <string>Up Arrow</string> </dict> </array> <key>Down</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>125</string> <key>elementName</key> <string>Down Arrow</string> </dict> </array> <key>Left</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>123</string> <key>elementName</key> <string>Left Arrow</string> </dict> </array> <key>Right</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>124</string> <key>elementName</key> <string>Right Arrow</string> </dict> </array> <key>A</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>7</string> <key>elementName</key> <string>X</string> </dict> </array> <key>B</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>6</string> <key>elementName</key> <string>Z</string> </dict> </array> <key>X</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>1</string> <key>elementName</key> <string>S</string> </dict> </array> <key>Y</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>0</string> <key>elementName</key> <string>A</string> </dict> </array> <key>L</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>12</string> <key>elementName</key> <string>Q</string> </dict> </array> <key>R</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>13</string> <key>elementName</key> <string>W</string> </dict> </array> <key>Start</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>36</string> <key>elementName</key> <string>Return</string> </dict> </array> <key>Select</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>48</string> <key>elementName</key> <string>Tab</string> </dict> </array> <key>Touch</key> <array> <dict> <key>deviceCode</key> <string>NSEventMouse</string> <key>deviceName</key> <string>Mouse</string> <key>elementCode</key> <string>0</string> <key>elementName</key> <string>Primary Button</string> <key>useInputForIntCoord</key> <true/> </dict> </array> <key>Microphone</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>50</string> <key>elementName</key> <string>` (Accent)</string> <key>intValue1</key> <integer>1</integer> </dict> </array> <key>Lid</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>51</string> <key>elementName</key> <string>Delete (Backspace)</string> </dict> </array> <key>Debug</key> <array/> <key>Guitar Grip: Green</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>14</string> <key>elementName</key> <string>E</string> </dict> </array> <key>Guitar Grip: Red</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>15</string> <key>elementName</key> <string>R</string> </dict> </array> <key>Guitar Grip: Yellow</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>17</string> <key>elementName</key> <string>T</string> </dict> </array> <key>Guitar Grip: Blue</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>16</string> <key>elementName</key> <string>Y</string> </dict> </array> <key>Piano: C</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>8</string> <key>elementName</key> <string>C</string> </dict> </array> <key>Piano: C#</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>3</string> <key>elementName</key> <string>F</string> </dict> </array> <key>Piano: D</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>9</string> <key>elementName</key> <string>V</string> </dict> </array> <key>Piano: D#</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>5</string> <key>elementName</key> <string>G</string> </dict> </array> <key>Piano: E</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>11</string> <key>elementName</key> <string>B</string> </dict> </array> <key>Piano: F</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>45</string> <key>elementName</key> <string>N</string> </dict> </array> <key>Piano: F#</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>38</string> <key>elementName</key> <string>J</string> </dict> </array> <key>Piano: G</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>46</string> <key>elementName</key> <string>M</string> </dict> </array> <key>Piano: G#</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>40</string> <key>elementName</key> <string>K</string> </dict> </array> <key>Piano: A</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>43</string> <key>elementName</key> <string>, (Comma)</string> </dict> </array> <key>Piano: A#</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>37</string> <key>elementName</key> <string>L</string> </dict> </array> <key>Piano: B</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>47</string> <key>elementName</key> <string>. (Period)</string> </dict> </array> <key>Piano: High C</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>44</string> <key>elementName</key> <string>/</string> </dict> </array> <key>Paddle</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>31</string> <key>elementName</key> <string>O</string> <key>intValue1</key> <integer>-5</integer> <key>isInputAnalog</key> <false/> </dict> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>35</string> <key>elementName</key> <string>P</string> <key>intValue1</key> <integer>5</integer> <key>isInputAnalog</key> <false/> </dict> </array> <key>Autohold - Set</key> <array/> <key>Autohold - Clear</key> <array/> <key>HUD</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>4</string> <key>elementName</key> <string>H</string> </dict> </array> <key>Execute/Pause</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>117</string> <key>elementName</key> <string>Forward Delete</string> </dict> </array> <key>Frame Advance</key> <array/> <key>Frame Jump</key> <array/> <key>Reset</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>121</string> <key>elementName</key> <string>Page Down</string> </dict> </array> <key>Mute/Unmute</key> <array/> <key>Load State Slot</key> <array/> <key>Save State Slot</key> <array/> <key>Copy Screen</key> <array/> <key>Rotate Display Left</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>33</string> <key>elementName</key> <string>[</string> <key>intValue0</key> <integer>-90</integer> </dict> </array> <key>Rotate Display Right</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>30</string> <key>elementName</key> <string>]</string> <key>intValue0</key> <integer>90</integer> </dict> </array> <key>Toggle All Displays</key> <array/> <key>Set Speed</key> <array> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>27</string> <key>elementName</key> <string>- (Dash)</string> <key>floatValue0</key> <string>0.5</string> </dict> <dict> <key>deviceCode</key> <string>NSEventKeyboard</string> <key>deviceName</key> <string>Keyboard</string> <key>elementCode</key> <string>24</string> <key>elementName</key> <string>=</string> <key>floatValue0</key> <integer>2</integer> </dict> </array> <key>Enable/Disable Speed Limiter</key> <array/> <key>Enable/Disable Auto Frame Skip</key> <array/> <key>Enable/Disable Cheat System</key> <array/> <key>Enable/Disable GPU State</key> <array/> </dict> <key>Input_SavedDeviceProperties</key> <dict/> <key>Input_SavedProfiles</key> <array/> <key>Microphone_HardwareMicMute</key> <false/> <key>Render3D_EdgeMarking</key> <true/> <key>Render3D_Fog</key> <true/> <key>Render3D_FragmentSamplingHack</key> <false/> <key>Render3D_ScalingFactor</key> <integer>1</integer> <key>Render3D_ColorFormat</key> <integer>536895878</integer> <key>Render3D_HighPrecisionColorInterpolation</key> <true/> <key>Render3D_LineHack</key> <true/> <key>Render3D_MultisampleSize</key> <integer>0</integer> <key>Render3D_RenderingEngine</key> <integer>1</integer> <key>Render3D_Textures</key> <true/> <key>Render3D_TextureScalingFactor</key> <integer>1</integer> <key>Render3D_TextureDeposterize</key> <false/> <key>Render3D_TextureSmoothing</key> <false/> <key>Render3D_Threads</key> <integer>0</integer> <key>Render3D_OpenGL_EmulateShadowPolygon</key> <true/> <key>Render3D_OpenGL_EmulateSpecialZeroAlphaBlending</key> <true/> <key>Render3D_OpenGL_EmulateNDSDepthCalculation</key> <true/> <key>Render3D_OpenGL_EmulateDepthLEqualPolygonFacing</key> <false/> <key>RomInfoPanel_SectionViewState</key> <dict/> <key>AVCaptureTool_DirectoryPath</key> <string>~/Movies</string> <key>AVCaptureTool_FileFormat</key> <integer>0</integer> <key>AVCaptureTool_DisplayMode</key> <integer>2</integer> <key>AVCaptureTool_DisplayRotation</key> <integer>0</integer> <key>AVCaptureTool_DisplaySeparation</key> <integer>0</integer> <key>AVCaptureTool_DisplayLayout</key> <integer>0</integer> <key>AVCaptureTool_DisplayOrder</key> <integer>0</integer> <key>AVCaptureTool_Deposterize</key> <false/> <key>AVCaptureTool_OutputFilter</key> <integer>1</integer> <key>AVCaptureTool_PixelScaler</key> <integer>0</integer> <key>AVCaptureTool_VideoSizeOption</key> <integer>0</integer> <key>AVCaptureTool_VideoWidth</key> <integer>256</integer> <key>AVCaptureTool_VideoHeight</key> <integer>384</integer> <key>ScreenshotCaptureTool_DirectoryPath</key> <string>~/Pictures</string> <key>ScreenshotCaptureTool_FileFormat</key> <integer>0</integer> <key>ScreenshotCaptureTool_DisplayMode</key> <integer>2</integer> <key>ScreenshotCaptureTool_DisplayScale</key> <integer>0</integer> <key>ScreenshotCaptureTool_DisplayRotation</key> <integer>0</integer> <key>ScreenshotCaptureTool_DisplaySeparation</key> <integer>0</integer> <key>ScreenshotCaptureTool_DisplayLayout</key> <integer>0</integer> <key>ScreenshotCaptureTool_DisplayOrder</key> <integer>0</integer> <key>ScreenshotCaptureTool_Deposterize</key> <false/> <key>ScreenshotCaptureTool_OutputFilter</key> <integer>1</integer> <key>ScreenshotCaptureTool_PixelScaler</key> <integer>0</integer> <key>Slot2_GBA_CartridgePath</key> <string></string> <key>Slot2_GBA_SRAMPath</key> <string></string> <key>Slot2_LoadedDevice</key> <integer>1</integer> <key>Slot2_MPCF_DirectoryPath</key> <string></string> <key>Slot2_MPCF_DiskImagePath</key> <string></string> <key>Slot2_MPCF_PathOption</key> <integer>0</integer> <key>Sound_AudioOutputEngine</key> <integer>58325</integer> <key>Sound_Volume</key> <integer>100</integer> <key>SPU_AdvancedLogic</key> <true/> <key>SPU_InterpolationMode</key> <integer>2</integer> <key>SPU_SyncMethod</key> <integer>0</integer> <key>SPU_SyncMode</key> <integer>1</integer> <key>Wifi_EmulationMode</key> <integer>0</integer> <key>Wifi_BridgeDeviceSelectionIndex</key> <integer>0</integer> <key>Wifi_BridgeDeviceSelectionName</key> <string></string> </dict> </plist> ```
/content/code_sandbox/desmume/src/frontend/cocoa/DefaultUserPrefs.plist
xml
2016-11-24T02:20:36
2024-08-16T13:18:50
desmume
TASEmulators/desmume
2,879
8,680
```xml import React from 'react' import { FlatList, FlatListProps } from 'react-native' import { ScrollViewWithOverlay, ScrollViewWithOverlayProps, } from './ScrollViewWithOverlay' export interface FlatListWithOverlayProps<TItem> extends FlatListProps<TItem>, ScrollViewWithOverlayProps { keyExtractor: NonNullable<FlatListProps<TItem>['keyExtractor']> } export const FlatListWithOverlay = React.forwardRef( (props: FlatListWithOverlayProps<any>, ref: any) => { return ( <ScrollViewWithOverlay ref={ref} {...props} ScrollViewComponent={FlatList} /> ) }, ) FlatListWithOverlay.displayName = 'FlatListWithOverlay' ```
/content/code_sandbox/packages/components/src/components/common/FlatListWithOverlay.tsx
xml
2016-11-30T23:24:21
2024-08-16T00:24:59
devhub
devhubapp/devhub
9,652
156
```xml /* * * * path_to_url * * Unless required by applicable law or agreed to in writing, software * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */ import classNames from "classnames"; import * as React from "react"; import { Classes, HTMLTable } from "@blueprintjs/core"; export interface ModifierTableProps { /** Table body contents. */ children?: React.ReactNode; /** Message to display when children is empty. */ emptyMessage?: string; /** Title of the first column, describing the type of each row in the table. */ title: string; /** Title of the second column */ descriptionTitle?: string; } export const ModifierTable: React.FunctionComponent<ModifierTableProps> = ({ children, descriptionTitle = "Description", emptyMessage, title, }) => ( <div className={classNames("docs-modifiers-table", Classes.RUNNING_TEXT)}> <HTMLTable> <thead> <tr> <th>{title}</th> <th>{descriptionTitle}</th> </tr> </thead> <tbody>{isEmpty(children) ? renderEmptyState(emptyMessage) : children}</tbody> </HTMLTable> </div> ); function isEmpty(children: React.ReactNode) { const array = React.Children.toArray(children); return array.length === 0 || array.filter(item => !!item).length === 0; } function renderEmptyState(message = "Nothing here.") { return ( <tr> <td colSpan={2}> <em className={Classes.TEXT_MUTED}>{message}</em> </td> </tr> ); } ```
/content/code_sandbox/packages/docs-theme/src/components/modifierTable.tsx
xml
2016-10-25T21:17:50
2024-08-16T15:14:48
blueprint
palantir/blueprint
20,593
351
```xml import React from 'react'; import PropTypes from 'prop-types'; import { localized } from 'mailspring-exports'; import { RetinaImg } from 'mailspring-component-kit'; import * as OnboardingActions from './onboarding-actions'; import AccountProviders from './account-providers'; export default class AccountChoosePage extends React.Component { static displayName = 'AccountChoosePage'; static propTypes = { account: PropTypes.object, }; _renderProviders() { return AccountProviders.map(({ icon, displayName, provider }) => ( <div key={provider} className={`provider ${provider}`} onClick={() => OnboardingActions.chooseAccountProvider(provider)} > <div className="icon-container"> <RetinaImg name={icon} mode={RetinaImg.Mode.ContentPreserve} className="icon" /> </div> <span className="provider-name">{displayName}</span> </div> )); } render() { return ( <div className="page account-choose"> <h2>{localized('Connect an email account')}</h2> <div className="provider-list">{this._renderProviders()}</div> </div> ); } } ```
/content/code_sandbox/app/internal_packages/onboarding/lib/page-account-choose.tsx
xml
2016-10-13T06:45:50
2024-08-16T18:14:37
Mailspring
Foundry376/Mailspring
15,331
253
```xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="path_to_url" xmlns:app="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical"> <razerdp.demo.widget.TitleBarView android:layout_width="match_parent" android:layout_height="wrap_content" app:title_text="Update" /> <TextView android:id="@+id/tv_test" android:layout_width="wrap_content" android:layout_height="wrap_content" android:background="@color/common_gray" android:gravity="center" android:padding="12dp" android:text="click me" android:textColor="@color/white" android:textSize="18sp" /> </LinearLayout> ```
/content/code_sandbox/app/src/main/res/layout/activity_update_test.xml
xml
2016-01-15T03:31:07
2024-08-14T02:03:47
BasePopup
razerdp/BasePopup
5,179
180
```xml import { DisplayObject } from '@antv/g'; import { deepMix } from '@antv/util'; import { group } from 'd3-array'; import { subObject } from '../utils/helper'; import { createDatumof, createValueof, mergeState, offsetTransform, renderBackground, renderLink, selectElementByData, selectG2Elements, selectPlotArea, useState, } from './utils'; /** * highlight a group of elements. */ export function elementHighlight( root: DisplayObject, { elements: elementsof, // given the root of chart returns elements to be manipulated datum, // given each element returns the datum of it groupKey = (d) => d, // group elements by specified key link = false, // draw link or not background = false, // draw background or not delay = 60, // delay to unhighlighted element scale, coordinate, emitter, state = {}, }: Record<string, any>, ) { const elements = elementsof(root); const elementSet = new Set(elements); const keyGroup = group(elements, groupKey); const valueof = createValueof(elements, datum); const [appendLink, removeLink] = renderLink({ elements, valueof, link, coordinate, ...subObject(state.active, 'link'), }); const [appendBackground, removeBackground, isBackground] = renderBackground({ document: root.ownerDocument, scale, coordinate, background, valueof, ...subObject(state.active, 'background'), }); const elementStyle = deepMix(state, { active: { ...(state.active?.offset && { //Apply translate to mock slice out. transform: (...params) => { const value = state.active.offset(...params); const [, i] = params; return offsetTransform(elements[i], value, coordinate); }, }), }, }); const { setState, removeState, hasState } = useState(elementStyle, valueof); let out; // Timer for delaying unhighlighted. const pointerover = (event) => { const { target: element, nativeEvent = true } = event; if (!elementSet.has(element)) return; if (out) clearTimeout(out); const k = groupKey(element); const group = keyGroup.get(k); const groupSet = new Set(group); for (const e of elements) { if (groupSet.has(e)) { if (!hasState(e, 'active')) setState(e, 'active'); } else { setState(e, 'inactive'); removeLink(e); } if (e !== element) removeBackground(e); } appendBackground(element); appendLink(group); // Emit events. if (!nativeEvent) return; emitter.emit('element:highlight', { nativeEvent, data: { data: datum(element), group: group.map(datum), }, }); }; const delayUnhighlighted = () => { if (out) clearTimeout(out); out = setTimeout(() => { unhighlighted(); out = null; }, delay); }; const unhighlighted = (nativeEvent = true) => { for (const e of elements) { removeState(e, 'active', 'inactive'); removeBackground(e); removeLink(e); } if (nativeEvent) { emitter.emit('element:unhighlight', { nativeEvent }); } }; const pointerout = (event) => { const { target: element } = event; if (background && !isBackground(element)) return; if (!background && !elementSet.has(element)) return; if (delay > 0) delayUnhighlighted(); else unhighlighted(); }; const pointerleave = () => { unhighlighted(); }; root.addEventListener('pointerover', pointerover); root.addEventListener('pointerout', pointerout); root.addEventListener('pointerleave', pointerleave); const onRest = (e) => { const { nativeEvent } = e; if (nativeEvent) return; unhighlighted(false); }; const onHighlight = (e) => { const { nativeEvent } = e; if (nativeEvent) return; const { data } = e.data; const element = selectElementByData(elements, data, datum); if (!element) return; pointerover({ target: element, nativeEvent: false }); }; emitter.on('element:highlight', onHighlight); emitter.on('element:unhighlight', onRest); return () => { root.removeEventListener('pointerover', pointerover); root.removeEventListener('pointerout', pointerout); root.removeEventListener('pointerleave', pointerleave); emitter.off('element:highlight', onHighlight); emitter.off('element:unhighlight', onRest); for (const e of elements) { removeBackground(e); removeLink(e); } }; } export function ElementHighlight({ delay, createGroup, background = false, link = false, ...rest }) { return (context, _, emitter) => { const { container, view, options } = context; const { scale, coordinate } = view; const plotArea = selectPlotArea(container); return elementHighlight(plotArea, { elements: selectG2Elements, datum: createDatumof(view), groupKey: createGroup ? createGroup(view) : undefined, coordinate, scale, state: mergeState(options, [ ['active', background ? {} : { lineWidth: '1', stroke: '#000' }], 'inactive', ]), background, link, delay, emitter, ...rest, }); }; } ElementHighlight.props = { reapplyWhenUpdate: true, }; ```
/content/code_sandbox/src/interaction/elementHighlight.ts
xml
2016-05-26T09:21:04
2024-08-15T16:11:17
G2
antvis/G2
12,060
1,270
```xml <!-- This is the civil flag, which does not have the national coat of arms in the centre --> <vector xmlns:android="path_to_url" android:width="240dp" android:height="180dp" android:viewportWidth="3" android:viewportHeight="2"> <path android:fillColor="#5eb6e4" android:pathData="M0,0h3v2h-3z"/> <path android:fillColor="#fff" android:pathData="M0,0h3v1h-3z"/> </vector> ```
/content/code_sandbox/app/src/main/res/drawable/ic_flag_sm.xml
xml
2016-07-02T10:44:04
2024-08-16T18:55:54
StreetComplete
streetcomplete/StreetComplete
3,781
121
```xml <?xml version="1.0" encoding="utf-8"?> <set xmlns:android="path_to_url" android:interpolator="@android:anim/bounce_interpolator" android:ordering="together"> <objectAnimator android:duration="150" android:propertyName="scaleX" android:repeatCount="3" android:repeatMode="reverse" android:valueFrom="1.0" android:valueTo="0.6" android:valueType="floatType" /> <objectAnimator android:duration="150" android:propertyName="scaleY" android:repeatCount="3" android:repeatMode="reverse" android:valueFrom="1.0" android:valueTo="0.6" android:valueType="floatType" /> </set> ```
/content/code_sandbox/saklib/src/main/res/animator/sak_shake_animator.xml
xml
2016-11-30T10:14:50
2024-08-12T19:26:20
SwissArmyKnife
android-notes/SwissArmyKnife
1,346
176
```xml import RouteWrapper from "~/components/wrappers/RouteWrapper"; import generateMeta from "~/utils/generateMeta"; import type { HandleCustom } from "~/components/Breadcrumbs/Breadcrumbs"; export const config = { group: "basic" }; export const handle: HandleCustom = { links: [{ label: "Home", link: "/", key: "home" }], }; export const meta = generateMeta("Home"); const filePath = "routes/index.tsx"; export default function HomePage() { return <RouteWrapper filePath={filePath}>Home Page</RouteWrapper>; } ```
/content/code_sandbox/packages/remix/test/fixtures-vite/02-interactive-remix-routing-v2/app/routes/_index.tsx
xml
2016-09-09T01:12:08
2024-08-16T17:39:45
vercel
vercel/vercel
12,545
117
```xml <?xml version="1.0" encoding="UTF-8"?> <definitions xmlns="path_to_url" xmlns:flowable="path_to_url" targetNamespace="Examples"> <process id="startToEnd"> <startEvent id="theStart" /> <sequenceFlow id="flow1" sourceRef="theStart" targetRef="task" /> <userTask id="task" flowable:assignee="testUser" /> <sequenceFlow id="flow2" sourceRef="task" targetRef="theEnd" /> <endEvent id="theEnd" /> </process> </definitions> ```
/content/code_sandbox/modules/flowable-engine/src/test/resources/org/flowable/engine/test/bpmn/oneTask.bpmn20.xml
xml
2016-10-13T07:21:43
2024-08-16T15:23:14
flowable-engine
flowable/flowable-engine
7,715
136
```xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical"> <TextView android:text="This attack sends random fake beacons." android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginTop="15dp" android:layout_marginLeft="10dp" android:layout_marginRight="10dp" android:id="@+id/tv_beaconflood_info" /> <Button android:id="@+id/button_start_beaconflood" android:layout_width="match_parent" android:layout_height="wrap_content" android:text="Start" android:paddingTop="15dp" android:paddingBottom="15dp" android:layout_marginTop="30dp" /> </LinearLayout> ```
/content/code_sandbox/app/app/src/main/res/layout/beaconflood_dialog.xml
xml
2016-10-27T09:31:28
2024-08-16T19:00:35
nexmon
seemoo-lab/nexmon
2,381
202
```xml import type { RequestConfig } from '../../common/types'; import type { Transaction, TransactionParams } from '../types'; import { request } from '../../utils/request'; export const createTransaction = ( config: RequestConfig, { walletId, data }: TransactionParams ): Promise<Transaction> => request( { method: 'POST', path: `/v2/wallets/${walletId}/transactions/`, ...config, }, {}, data ); ```
/content/code_sandbox/source/renderer/app/api/transactions/requests/createTransaction.ts
xml
2016-10-05T13:48:54
2024-08-13T22:03:19
daedalus
input-output-hk/daedalus
1,230
100
```xml <vector xmlns:android="path_to_url" xmlns:aapt="path_to_url" android:width="48dp" android:height="48dp" android:viewportWidth="48" android:viewportHeight="48"> <path android:pathData="M11,6H37C38.657,6 40,7.343 40,9V39C40,40.657 38.657,42 37,42H11C9.343,42 8,40.657 8,39V9C8,7.343 9.343,6 11,6ZM25,15C24.448,15 24,15.448 24,16V34C24,34.552 24.448,35 25,35H28C28.552,35 29,34.552 29,34V16C29,15.448 28.552,15 28,15H25ZM18,27C18,26.448 18.448,26 19,26H22C22.552,26 23,26.448 23,27V34C23,34.552 22.552,35 22,35H19C18.448,35 18,34.552 18,34V27ZM13,31C12.448,31 12,31.448 12,32V34C12,34.552 12.448,35 13,35H16C16.552,35 17,34.552 17,34V32C17,31.448 16.552,31 16,31H13ZM12.5,36C12.224,36 12,36.224 12,36.5C12,36.776 12.224,37 12.5,37H34.5C34.776,37 35,36.776 35,36.5C35,36.224 34.776,36 34.5,36H12.5ZM30,22C30,21.448 30.448,21 31,21H34C34.552,21 35,21.448 35,22V34C35,34.552 34.552,35 34,35H31C30.448,35 30,34.552 30,34V22Z" android:fillType="evenOdd"> <aapt:attr name="android:fillColor"> <gradient android:startX="24" android:startY="6" android:endX="24" android:endY="42" android:type="linear"> <item android:offset="0" android:color="#FF29DD74"/> <item android:offset="1" android:color="#FF09BF5B"/> </gradient> </aapt:attr> </path> </vector> ```
/content/code_sandbox/icon-pack/src/main/res/drawable/ic_numbers_medium_solid.xml
xml
2016-05-04T11:46:20
2024-08-15T16:29:10
android
meganz/android
1,537
647
```xml import { checkPermission } from '@erxes/api-utils/src/permissions'; import { WEBHOOK_STATUS } from '../../../models/definitions/constants'; import { IWebhook } from '../../../models/definitions/webhooks'; import { putCreateLog, putDeleteLog, putUpdateLog } from '../../../logUtils'; import { IContext } from '../../../connectionResolver'; import fetch from 'node-fetch'; interface IWebhookEdit extends IWebhook { _id: string; } const WEBHOOK = 'webhook'; const webhookMutations = { /** * Creates a new webhook */ async webhooksAdd( _root, doc: IWebhook, { user, docModifier, models, subdomain }: IContext, ) { const webhook = await models.Webhooks.createWebhook(docModifier(doc)); await fetch(webhook.url, { headers: { 'Erxes-token': webhook.token || '', 'Content-Type': 'application/json', }, method: 'post', body: JSON.stringify({ text: 'You have successfully connected erxes webhook', }), }) .then(async () => { await models.Webhooks.updateStatus( webhook._id, WEBHOOK_STATUS.AVAILABLE, ); }) .catch(async (err) => { console.log('error ', err); await models.Webhooks.updateStatus( webhook._id, WEBHOOK_STATUS.UNAVAILABLE, ); }); await putCreateLog( subdomain, { type: WEBHOOK, newData: webhook, object: webhook, description: `${webhook.url} has been created`, }, user, ); return webhook; }, /** * Edits a webhook */ async webhooksEdit( _root, { _id, ...doc }: IWebhookEdit, { user, models, subdomain }: IContext, ) { const webhook = await models.Webhooks.getWebHook(_id); const updated = await models.Webhooks.updateWebhook(_id, doc); await fetch(webhook.url, { headers: { 'Erxes-token': webhook.token || '', 'Content-Type': 'application/json', }, method: 'post', body: JSON.stringify({ text: 'You have successfully connected erxes webhook', }), }) .then(async () => { await models.Webhooks.updateStatus( webhook._id, WEBHOOK_STATUS.AVAILABLE, ); }) .catch(async (err) => { console.log('error ', err); await models.Webhooks.updateStatus( webhook._id, WEBHOOK_STATUS.UNAVAILABLE, ); }); await putUpdateLog( subdomain, { type: WEBHOOK, object: webhook, newData: doc, description: `${webhook.url} has been edited`, }, user, ); return updated; }, /** * Removes a webhook */ async webhooksRemove( _root, { _id }: { _id: string }, { models, subdomain, user }: IContext, ) { const webhook = await models.Webhooks.getWebHook(_id); const removed = await models.Webhooks.removeWebhooks(_id); await putDeleteLog( subdomain, { type: WEBHOOK, object: webhook, description: `${webhook.url} has been removed`, }, user, ); return removed; }, }; checkPermission(webhookMutations, 'webhooksAdd', 'manageWebhooks'); checkPermission(webhookMutations, 'webhooksEdit', 'manageWebhooks'); checkPermission(webhookMutations, 'webhooksRemove', 'manageWebhooks'); export default webhookMutations; ```
/content/code_sandbox/packages/plugin-webhooks-api/src/graphql/resolvers/mutations/webhooks.ts
xml
2016-11-11T06:54:50
2024-08-16T10:26:06
erxes
erxes/erxes
3,479
806
```xml namespace pxsim.util { export function injectPolyphils() { // path_to_url if (!String.prototype.startsWith) { Object.defineProperty(String.prototype, 'startsWith', { value: function(search: string, pos: number) { if (search === undefined || search == null) return false; pos = !pos || pos < 0 ? 0 : +pos; return (<string>this).substring(pos, pos + search.length) === search; } }); } // path_to_url if (!Array.prototype.fill) { Object.defineProperty(Array.prototype, 'fill', { writable: true, enumerable: true, value: function (value: Array<any>) { // Steps 1-2. if (this == null) { throw new TypeError('this is null or not defined'); } let O = Object(this); // Steps 3-5. let len = O.length >>> 0; // Steps 6-7. let start = arguments[1]; let relativeStart = start >> 0; // Step 8. let k = relativeStart < 0 ? Math.max(len + relativeStart, 0) : Math.min(relativeStart, len); // Steps 9-10. let end = arguments[2]; let relativeEnd = end === undefined ? len : end >> 0; // Step 11. let final = relativeEnd < 0 ? Math.max(len + relativeEnd, 0) : Math.min(relativeEnd, len); // Step 12. while (k < final) { O[k] = value; k++; } // Step 13. return O; } }); } // path_to_url if (!Array.prototype.find) { Object.defineProperty(Array.prototype, 'find', { writable: true, enumerable: true, value: function (predicate: (value: any, index: number, obj: any[]) => boolean) { // 1. Let O be ? ToObject(this value). if (this == null) { throw new TypeError('"this" is null or not defined'); } let o = Object(this); // 2. Let len be ? ToLength(? Get(O, "length")). const len = o.length >>> 0; // 3. If IsCallable(predicate) is false, throw a TypeError exception. if (typeof predicate !== 'function') { throw new TypeError('predicate must be a function'); } // 4. If thisArg was supplied, let T be thisArg; else let T be undefined. const thisArg = arguments[1]; // 5. Let k be 0. let k = 0; // 6. Repeat, while k < len while (k < len) { // a. Let Pk be ! ToString(k). // b. Let kValue be ? Get(O, Pk). // c. Let testResult be ToBoolean(? Call(predicate, T, kValue, k, O )). // d. If testResult is true, return kValue. const kValue = o[k]; if (predicate.call(thisArg, kValue, k, o)) { return kValue; } // e. Increase k by 1. k++; } // 7. Return undefined. return undefined; }, }); } // Polyfill for Uint8Array.slice for IE and Safari // path_to_url#sec-%typedarray%.prototype.slice // TODO: Move this polyfill to a more appropriate file. It is left here for now because moving it causes a crash in IE; see PXT issue #1301. if (!Uint8Array.prototype.slice) { Object.defineProperty(Uint8Array.prototype, 'slice', { value: Array.prototype.slice, writable: true, enumerable: true }); } if (!Uint16Array.prototype.slice) { Object.defineProperty(Uint16Array.prototype, 'slice', { value: Array.prototype.slice, writable: true, enumerable: true }); } if (!Uint32Array.prototype.slice) { Object.defineProperty(Uint32Array.prototype, 'slice', { value: Array.prototype.slice, writable: true, enumerable: true }); } // path_to_url#sec-%typedarray%.prototype.fill if (!Uint8Array.prototype.fill) { Object.defineProperty(Uint8Array.prototype, 'fill', { value: Array.prototype.fill, writable: true, enumerable: true }); } if (!Uint16Array.prototype.fill) { Object.defineProperty(Uint16Array.prototype, 'fill', { value: Array.prototype.fill, writable: true, enumerable: true }); } if (!Uint32Array.prototype.fill) { Object.defineProperty(Uint32Array.prototype, 'fill', { value: Array.prototype.fill, writable: true, enumerable: true }); } // path_to_url#sec-%typedarray%.prototype.some if (!Uint8Array.prototype.some) { Object.defineProperty(Uint8Array.prototype, 'some', { value: Array.prototype.some, writable: true, enumerable: true }); } if (!Uint16Array.prototype.some) { Object.defineProperty(Uint16Array.prototype, 'some', { value: Array.prototype.some, writable: true, enumerable: true }); } if (!Uint32Array.prototype.some) { Object.defineProperty(Uint32Array.prototype, 'some', { value: Array.prototype.some, writable: true, enumerable: true }); } // path_to_url#sec-%typedarray%.prototype.reverse if (!Uint8Array.prototype.reverse) { Object.defineProperty(Uint8Array.prototype, 'reverse', { value: Array.prototype.reverse, writable: true, enumerable: true }); } if (!Uint16Array.prototype.reverse) { Object.defineProperty(Uint16Array.prototype, 'reverse', { value: Array.prototype.reverse, writable: true, enumerable: true }); } if (!Uint32Array.prototype.reverse) { Object.defineProperty(Uint32Array.prototype, 'reverse', { value: Array.prototype.reverse, writable: true, enumerable: true }); } // Inject Math imul polyfill if (!Math.imul) { // for explanations see: // path_to_url (second answer) // (but the code below doesn't come from there; I wrote it myself) // TODO use Math.imul if available Math.imul = function (a: number, b: number): number { const ah = (a >>> 16) & 0xffff; const al = a & 0xffff; const bh = (b >>> 16) & 0xffff; const bl = b & 0xffff; // the shift by 0 fixes the sign on the high part // the final |0 converts the unsigned value into a signed value return ((al * bl) + (((ah * bl + al * bh) << 16) >>> 0) | 0); } } // path_to_url#Polyfill if (typeof Object.assign != 'function') { // Must be writable: true, enumerable: false, configurable: true Object.defineProperty(Object, "assign", { value: function assign(target: any, varArgs: any) { // .length of function is 2 'use strict'; if (target == null) { // TypeError if undefined or null throw new TypeError('Cannot convert undefined or null to object'); } let to = Object(target); for (let index = 1; index < arguments.length; index++) { let nextSource = arguments[index]; if (nextSource != null) { // Skip over if undefined or null for (let nextKey in nextSource) { // Avoid bugs when hasOwnProperty is shadowed if (Object.prototype.hasOwnProperty.call(nextSource, nextKey)) { to[nextKey] = nextSource[nextKey]; } } } } return to; }, writable: true, configurable: true }); } // path_to_url if (!Promise.prototype.finally) { Promise.prototype.finally = Promise.prototype.finally || { finally (fn: () => void): Promise<any> { const onFinally = (callback: () => Promise<any>) => Promise.resolve(fn()).then(callback); return (this as Promise<any>).then( result => onFinally(() => result), reason => onFinally(() => Promise.reject(reason)) ); } }.finally; } } export class Lazy<T> { private _value: T; private _evaluated = false; constructor(private _func: () => T) { } get value(): T { if (!this._evaluated) { this._value = this._func(); this._evaluated = true; } return this._value; } } export function getNormalizedParts(path: string): string[] { path = path.replace(/\\/g, "/"); const parts: string[] = []; path.split("/").forEach(part => { if (part === ".." && parts.length) { parts.pop(); } else if (part && part !== ".") { parts.push(part) } }); return parts; } export function normalizePath(path: string): string { return getNormalizedParts(path).join("/"); } export function relativePath(fromDir: string, toFile: string): string { const fParts = getNormalizedParts(fromDir); const tParts = getNormalizedParts(toFile); let i = 0; while (fParts[i] === tParts[i]) { i++; if (i === fParts.length || i === tParts.length) { break; } } const fRemainder = fParts.slice(i); const tRemainder = tParts.slice(i); for (let i = 0; i < fRemainder.length; i++) { tRemainder.unshift(".."); } return tRemainder.join("/"); } export function pathJoin(...paths: string[]): string { let result = ""; paths.forEach(path => { path.replace(/\\/g, "/"); if (path.lastIndexOf("/") === path.length - 1) { path = path.slice(0, path.length - 1) } result += "/" + path; }); return result; } export function toArray<T>(a: ArrayLike<T> | ReadonlyArray<T>): T[] { if (Array.isArray(a)) { return a; } let r: T[] = [] for (let i = 0; i < a.length; ++i) r.push(a[i]) return r } } ```
/content/code_sandbox/pxtsim/utils.ts
xml
2016-01-24T19:35:52
2024-08-16T16:39:39
pxt
microsoft/pxt
2,069
2,389
```xml import { screen } from "@testing-library/react"; import customRenderAppWithContext from "coral-stream/test/customRenderAppWithContext"; import { commentWithRejectedReply, replyableComment, settings, stories, unrepliableComment, } from "../../fixtures"; import create from "./create"; const story = stories[0]; const createTestRenderer = async () => { const resolvers = { Query: { comment: () => commentWithRejectedReply, settings: () => settings, story: () => story, }, }; const { context } = create({ resolvers, initLocalState: (localRecord) => { localRecord.setValue(story.id, "storyID"); localRecord.setValue(commentWithRejectedReply.id, "commentID"); }, }); customRenderAppWithContext(context); }; it("allows replies to comments with canReply = true", async () => { await createTestRenderer(); const shouldBeEnabled = await screen.findByLabelText( `Reply to comment by ${replyableComment.author?.username}`, { exact: false } ); expect(shouldBeEnabled).toBeEnabled(); }); it("disallows replies to comments with canReply = false", async () => { await createTestRenderer(); const shouldBeDisabled = await screen.findByLabelText( `Reply to comment by ${unrepliableComment.author?.username}`, { exact: false } ); expect(shouldBeDisabled).toBeDisabled(); }); ```
/content/code_sandbox/client/src/core/client/stream/test/comments/permalink/permalinkViewRejectedComment.spec.tsx
xml
2016-10-31T16:14:05
2024-08-06T16:15:57
talk
coralproject/talk
1,881
309
```xml import path from 'path'; import { yarnOrNpmSpawn } from '@electron-forge/core-utils'; import * as testUtils from '@electron-forge/test-utils'; import { expect } from 'chai'; import glob from 'fast-glob'; import fs from 'fs-extra'; import { api } from '../../../api/core'; import { initLink } from '../../../api/core/src/api/init-scripts/init-link'; describe('WebpackTypeScriptTemplate', () => { let dir: string; before(async () => { await yarnOrNpmSpawn(['link:prepare']); dir = await testUtils.ensureTestDirIsNonexistent(); }); it('should succeed in initializing the typescript template', async () => { await api.init({ dir, template: path.resolve(__dirname, '..', 'src', 'WebpackTypeScriptTemplate'), interactive: false, }); }); context('template files are copied to project', () => { const expectedFiles = [ 'tsconfig.json', '.eslintrc.json', 'forge.config.ts', 'webpack.main.config.ts', 'webpack.renderer.config.ts', 'webpack.rules.ts', 'webpack.plugins.ts', path.join('src', 'index.ts'), path.join('src', 'renderer.ts'), path.join('src', 'preload.ts'), ]; for (const filename of expectedFiles) { it(`${filename} should exist`, async () => { await testUtils.expectProjectPathExists(dir, filename, 'file'); }); } }); it('should ensure js source files from base template are removed', async () => { const jsFiles = await glob(path.join(dir, 'src', '**', '*.js')); expect(jsFiles.length).to.equal(0, `The following unexpected js files were found in the src/ folder: ${JSON.stringify(jsFiles)}`); }); describe('lint', () => { it('should initially pass the linting process', async () => { delete process.env.TS_NODE_PROJECT; await testUtils.expectLintToPass(dir); }); }); describe('package', () => { let cwd: string; before(async () => { delete process.env.TS_NODE_PROJECT; // Webpack resolves plugins via cwd cwd = process.cwd(); process.chdir(dir); // We need the version of webpack to match exactly during development due to a quirk in // typescript type-resolution. In prod no one has to worry about things like this const pj = await fs.readJson(path.resolve(dir, 'package.json')); pj.resolutions = { // eslint-disable-next-line @typescript-eslint/no-var-requires webpack: `${require('../../../../node_modules/webpack/package.json').version}`, }; await fs.writeJson(path.resolve(dir, 'package.json'), pj); await yarnOrNpmSpawn(['install'], { cwd: dir, }); // Installing deps removes symlinks that were added at the start of this // spec via `api.init`. So we should re-link local forge dependencies // again. await initLink(dir); }); after(() => { process.chdir(cwd); }); it('should pass', async () => { await api.package({ dir, interactive: false, }); }); }); after(async () => { await yarnOrNpmSpawn(['link:remove']); await fs.remove(dir); }); }); ```
/content/code_sandbox/packages/template/webpack-typescript/test/WebpackTypeScript_spec_slow.ts
xml
2016-10-05T14:51:53
2024-08-15T20:08:12
forge
electron/forge
6,380
732
```xml const ExmThanks = { async createdUser(exmThank) { return ( exmThank.createdBy && { __typename: 'User', _id: exmThank.createdBy } ); }, async recipients({ recipientIds }) { return (recipientIds || []).map(_id => ({ __typename: 'User', _id })); } }; export default ExmThanks; ```
/content/code_sandbox/packages/plugin-exmfeed-api/src/graphql/resolvers/exmThank.ts
xml
2016-11-11T06:54:50
2024-08-16T10:26:06
erxes
erxes/erxes
3,479
92
```xml import type { ContactGroup } from './Contact'; export interface GroupsWithCount extends ContactGroup { count: number; } ```
/content/code_sandbox/packages/shared/lib/interfaces/contacts/GroupsWithCount.ts
xml
2016-06-08T11:16:51
2024-08-16T14:14:27
WebClients
ProtonMail/WebClients
4,300
26
```xml <?xml version="1.0" encoding="utf-8"?> <FrameLayout xmlns:android="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent"> <View android:id="@+id/view_background" android:layout_width="match_parent" android:layout_height="match_parent" android:alpha="0" android:background="@android:color/black" /> <razerdp.demo.widget.viewpager.HackyViewPager android:id="@+id/view_pager" android:layout_width="match_parent" android:layout_height="match_parent" /> <razerdp.demo.widget.viewpager.IndicatorContainer android:id="@+id/view_indicator" android:layout_width="match_parent" android:layout_height="4dp" android:layout_gravity="bottom" android:layout_margin="16dp" /> </FrameLayout> ```
/content/code_sandbox/app/src/main/res/layout/activity_image_browser.xml
xml
2016-01-15T03:31:07
2024-08-14T02:03:47
BasePopup
razerdp/BasePopup
5,179
199
```xml import { expect } from 'chai'; import { Builder, WebDriver } from 'selenium-webdriver'; import { OPENVIDU_CALL_SERVER } from '../config'; import { WebComponentConfig } from '../selenium.conf'; import { OpenViduComponentsPO } from '../utils.po.test'; const url = `${WebComponentConfig.appUrl}?OV_URL=${OPENVIDU_CALL_SERVER}`; describe('Testing CHAT features', () => { let browser: WebDriver; let utils: OpenViduComponentsPO; async function createChromeBrowser(): Promise<WebDriver> { return await new Builder() .forBrowser(WebComponentConfig.browserName) .withCapabilities(WebComponentConfig.browserCapabilities) .setChromeOptions(WebComponentConfig.browserOptions) .usingServer(WebComponentConfig.seleniumAddress) .build(); } beforeEach(async () => { browser = await createChromeBrowser(); utils = new OpenViduComponentsPO(browser); }); afterEach(async () => { await browser.quit(); }); it('should send messages', async () => { await browser.get(`${url}&prejoin=false`); await utils.checkLayoutPresent(); await utils.togglePanel('chat'); await browser.sleep(500); await utils.waitForElement('.sidenav-menu'); await utils.waitForElement('.input-container'); expect(await utils.isPresent('.input-container')).to.be.true; const input = await utils.waitForElement('#chat-input'); await input.sendKeys('Test message'); await utils.clickOn('#send-btn'); await utils.waitForElement('.message'); await utils.getNumberOfElements('.message'); expect(await utils.isPresent('.message')).to.be.true; expect(await utils.getNumberOfElements('.message')).equals(1); await input.sendKeys('Test message'); await utils.clickOn('#send-btn'); expect(await utils.getNumberOfElements('.message')).equals(2); }); it('should receive a message', async () => { const roomName = 'chattingE2E'; let pName = `participant${Math.floor(Math.random() * 1000)}`; const fixedUrl = `${url}&prejoin=false&roomName=${roomName}`; await browser.get(fixedUrl); await browser.sleep(1000); await utils.checkLayoutPresent(); // Starting new browser for adding a new participant const newTabScript = `window.open("${fixedUrl}&participantName=${pName}")`; await browser.executeScript(newTabScript); const tabs = await browser.getAllWindowHandles(); browser.switchTo().window(tabs[1]); await utils.checkLayoutPresent(); await utils.togglePanel('chat'); await browser.sleep(1000); await utils.waitForElement('.sidenav-menu'); await utils.waitForElement('.input-container'); expect(await utils.isPresent('.input-container')).to.be.true; const input = await utils.waitForElement('#chat-input'); await input.sendKeys('test message'); await utils.clickOn('#send-btn'); // Go to first tab browser.switchTo().window(tabs[0]); await utils.waitForElement('.snackbarNotification'); await utils.togglePanel('chat'); await browser.sleep(1000); await utils.waitForElement('.message'); const participantName = await utils.waitForElement('.participant-name-container>p'); expect(await utils.getNumberOfElements('.message')).equals(1); expect(await participantName.getText()).equals(pName); }); it('should send an url message and converts in a link', async () => { await browser.get(`${url}&prejoin=false`); await utils.checkLayoutPresent(); await utils.togglePanel('chat'); await browser.sleep(500); await utils.waitForElement('.sidenav-menu'); await utils.waitForElement('.input-container'); expect(await utils.isPresent('.input-container')).to.be.true; const input = await utils.waitForElement('#chat-input'); await input.sendKeys('demos.openvidu.io'); await utils.clickOn('#send-btn'); await utils.waitForElement('.chat-message a'); expect(await utils.isPresent('.chat-message a')).to.be.true; }); }); ```
/content/code_sandbox/openvidu-components-angular/e2e/webcomponent-e2e/chat.test.ts
xml
2016-10-10T13:31:27
2024-08-15T12:14:04
openvidu
OpenVidu/openvidu
1,859
861
```xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="path_to_url" xmlns:tools="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_gravity="center" android:layout_margin="16dp" android:orientation="vertical" tools:context=".MainActivity"> <TextView android:id="@+id/textView" android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center" android:text="Separated by Commas" android:textSize="18sp" /> <MultiAutoCompleteTextView android:id="@+id/multiAutoCompleteTextView" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_margin="20dp" android:ems="10" android:hint="Enter here" /> <TextView android:layout_width="match_parent" android:layout_height="wrap_content" android:gravity="center" android:text="Separated by Custom Token" android:textSize="18sp" /> <MultiAutoCompleteTextView android:id="@+id/multiAutoCompleteTextViewCustom" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_margin="20dp" android:ems="10" android:hint="Add tags here" /> </LinearLayout> ```
/content/code_sandbox/Android/AndroidMultiAutoCompleteTextView/app/src/main/res/layout/activity_main.xml
xml
2016-05-02T05:43:21
2024-08-16T06:51:39
journaldev
WebJournal/journaldev
1,314
318
```xml /** * @private */ export class DeepMapEntry<T> { private root: Map<any, any> private closest: Map<any, any> private closestIdx: number = 0 isDisposed = false constructor(private base: Map<any, any>, private args: any[]) { let current: undefined | Map<any, any> = (this.closest = this.root = base) let i = 0 for (; i < this.args.length - 1; i++) { current = current!.get(args[i]) if (current) this.closest = current else break } this.closestIdx = i } exists(): boolean { this.assertNotDisposed() const l = this.args.length return this.closestIdx >= l - 1 && this.closest.has(this.args[l - 1]) } get(): T { this.assertNotDisposed() if (!this.exists()) throw new Error("Entry doesn't exist") return this.closest.get(this.args[this.args.length - 1]) } set(value: T) { this.assertNotDisposed() const l = this.args.length let current: Map<any, any> = this.closest // create remaining maps for (let i = this.closestIdx; i < l - 1; i++) { const m = new Map() current.set(this.args[i], m) current = m } this.closestIdx = l - 1 this.closest = current current.set(this.args[l - 1], value) } delete() { this.assertNotDisposed() if (!this.exists()) throw new Error("Entry doesn't exist") const l = this.args.length this.closest.delete(this.args[l - 1]) // clean up remaining maps if needed (reconstruct stack first) let c = this.root const maps: Map<any, any>[] = [c] for (let i = 0; i < l - 1; i++) { c = c.get(this.args[i])! maps.push(c) } for (let i = maps.length - 1; i > 0; i--) { if (maps[i].size === 0) maps[i - 1].delete(this.args[i - 1]) } this.isDisposed = true } private assertNotDisposed() { // TODO: once this becomes annoying, we should introduce a reset method to re-run the constructor logic if (this.isDisposed) throw new Error("Concurrent modification exception") } } /** * @private */ export class DeepMap<T> { private store = new Map<any, any>() private argsLength = -1 private last: DeepMapEntry<T> | undefined entry(args: any[]): DeepMapEntry<T> { if (this.argsLength === -1) this.argsLength = args.length else if (this.argsLength !== args.length) throw new Error( `DeepMap should be used with functions with a consistent length, expected: ${this.argsLength}, got: ${args.length}` ) if (this.last) this.last.isDisposed = true return (this.last = new DeepMapEntry(this.store, args)) } } ```
/content/code_sandbox/src/deepMap.ts
xml
2016-08-07T20:37:49
2024-08-10T13:14:54
mobx-utils
mobxjs/mobx-utils
1,182
701
```xml <?xml version="1.0" encoding="utf-8"?> <browserconfig> <msapplication> <tile> <square70x70logo src="/mstile-70x70.png"/> <square150x150logo src="/mstile-150x150.png"/> <square310x310logo src="/mstile-310x310.png"/> <wide310x150logo src="/mstile-310x150.png"/> <TileColor>#492c14</TileColor> </tile> </msapplication> </browserconfig> ```
/content/code_sandbox/public/browserconfig.xml
xml
2016-03-30T02:31:33
2024-08-12T00:51:08
freecodecamp.cn
huluoyang/freecodecamp.cn
5,523
121
```xml import { trackEvent } from ".."; export const trackMv3MigrationStarted = (total_count: number) => { trackEvent("mv3_migration_started", { total_count }); }; export const trackMv3MigrationRulesMigrated = ( total_count: number, migrated_count: number, impacted_count: number, path_impacted_count: number, page_url_impacted_count: number ) => { trackEvent("mv3_migration_rules_migrated", { total_count, migrated_count, impacted_count, path_impacted_count, page_url_impacted_count, }); }; export const trackMv3MigrationCompleted = (total_count: number, migrated_count: number) => { trackEvent("mv3_migration_completed", { total_count, migrated_count }); }; ```
/content/code_sandbox/app/src/modules/analytics/events/migrations.ts
xml
2016-12-01T04:36:06
2024-08-16T19:12:19
requestly
requestly/requestly
2,121
169
```xml import { SPHttpClient, SPHttpClientResponse } from '@microsoft/sp-http'; import { IWebPartContext } from '@microsoft/sp-webpart-base'; import ITodoDataProvider from '../dataProviders/ITodoDataProvider'; import { ITodoItem, ITaskList } from '../models/ICommonObjects'; export default class SharePointDataProvider implements ITodoDataProvider { private _selectedList: ITaskList; private _webPartContext: IWebPartContext; public set webPartContext(value: IWebPartContext) { this._webPartContext = value; } public get webPartContext(): IWebPartContext { return this._webPartContext; } public set selectedList(value: ITaskList) { this._selectedList = value; } public get selectedList(): ITaskList { return this._selectedList; } public getTaskLists(): Promise<ITaskList[]> { const listTemplateId: string = '171'; const queryUrl: string = `${this._webPartContext.pageContext.web.absoluteUrl}/_api/web/lists?$filter=BaseTemplate eq ${listTemplateId}`; return this._webPartContext.spHttpClient.get(queryUrl, SPHttpClient.configurations.v1) .then((response: SPHttpClientResponse) => { return response.json(); }) .then((json: { value: ITaskList[] }) => { return json.value; }); } public getItems(): Promise<ITodoItem[]> { const queryUrl: string = `${this._webPartContext.pageContext.web.absoluteUrl}` + `/_api/web/lists(guid'${this._selectedList.Id}')/items?$select=Id,Title,PercentComplete`; return this.webPartContext.spHttpClient.get(queryUrl, SPHttpClient.configurations.v1) .then((response: SPHttpClientResponse) => { return response.json(); }) .then((json: any) => { return json.value.map((item: any) => { let newItem: ITodoItem = { Id: item.Id, Title: item.Title, PercentComplete: item.PercentComplete }; return newItem; }); }); } public createItem(title: string): Promise<ITodoItem[]> { const body: {} = { '@data.type': this._selectedList.ListItemEntityTypeFullName, 'Title': title }; return this._webPartContext.spHttpClient.post(`${this._webPartContext.pageContext.web.absoluteUrl}/_api/web/lists(guid'${this._selectedList.Id}')/items`, SPHttpClient.configurations.v1, { body: JSON.stringify(body) }) .then(() => { return this.getItems(); }); } public deleteItem(itemToBeDeleted: ITodoItem): Promise<ITodoItem[]> { const itemDeletedUrl: string = `${this._webPartContext.pageContext.web.absoluteUrl}/_api/web/lists(guid'${this._selectedList.Id}')/items(${itemToBeDeleted.Id})`; const headers: Headers = new Headers(); headers.append('If-Match', '*'); return this.webPartContext.spHttpClient.fetch(itemDeletedUrl, SPHttpClient.configurations.v1, { headers, method: 'DELETE' } ).then((response: any) => { if (response.status >= 200 && response.status < 300) { return response; } else { return Promise.reject(new Error(JSON.stringify(response))); } }).then(() => { return this.getItems(); }); } public updateItem(itemUpdated: ITodoItem): Promise<ITodoItem[]> { const itemUpdatedUrl: string = `${this._webPartContext.pageContext.web.absoluteUrl}/_api/web/lists(guid'${this._selectedList.Id}')/items(${itemUpdated.Id})`; const headers: Headers = new Headers(); headers.append('If-Match', '*'); const body: {} = { '@data.type': this._selectedList.ListItemEntityTypeFullName, 'PercentComplete': itemUpdated.PercentComplete }; return this._webPartContext.spHttpClient.fetch(itemUpdatedUrl, SPHttpClient.configurations.v1, { body: JSON.stringify(body), headers, method: 'PATCH' }).then(() => { return this.getItems(); }); } } ```
/content/code_sandbox/samples/vuejs-todo-single-file-component/src/dataProviders/SharePointDataProvider.ts
xml
2016-08-30T17:21:43
2024-08-16T18:41:32
sp-dev-fx-webparts
pnp/sp-dev-fx-webparts
2,027
924
```xml import { CommonModule } from '@angular/common'; import { NgModule } from '@angular/core'; import { SplitButtonDocModule } from '@doc/splitbutton/splitbuttondoc.module'; import { SplitButtonDemo } from './splitbuttondemo'; import { SplitButtonDemoRoutingModule } from './splitbuttondemo-routing.module'; @NgModule({ imports: [CommonModule, SplitButtonDemoRoutingModule, SplitButtonDocModule], declarations: [SplitButtonDemo] }) export class SplitButtonDemoModule {} ```
/content/code_sandbox/src/app/showcase/pages/splitbutton/splitbuttondemo.module.ts
xml
2016-01-16T09:23:28
2024-08-16T19:58:20
primeng
primefaces/primeng
9,969
100
```xml export interface ModalElement { id: string title?: React.ReactNode content: React.ReactNode showCloseIcon?: boolean width: 'large' | 'default' | 'small' | 'full' | 'fit' | number height?: number maxHeight?: number minHeight?: number position?: { left: number right: number top: number bottom: number alignment: ContextModalAlignment } hideBackground?: boolean removePadding?: boolean onBlur?: boolean navigation?: ModalNavigationProps onClose?: () => void } export type ModalNavigationProps = { url: string fallbackUrl?: string } export type ContextModalAlignment = | 'bottom-left' | 'bottom-right' | 'top-left' | 'right' export type ModalOpeningOptions = { removePadding?: boolean showCloseIcon?: boolean keepAll?: boolean width?: 'large' | 'default' | 'small' | 'full' | 'fit' | number hideBackground?: boolean title?: string navigation?: ModalNavigationProps onClose?: () => void } export type ContextModalOpeningOptions = ModalOpeningOptions & { alignment?: ContextModalAlignment hideBackground?: boolean removePadding?: boolean onBlur?: boolean maxHeight?: number height?: number minHeight?: number } export interface ModalsContext { modals: ModalElement[] openContextModal: ( event: React.MouseEvent<Element>, modalContent: JSX.Element, options?: ContextModalOpeningOptions ) => void openModal: (modalContent: JSX.Element, options?: ModalOpeningOptions) => void closeAllModals: () => void closeLastModal: () => void } ```
/content/code_sandbox/src/design/lib/stores/modal/types.ts
xml
2016-11-19T14:30:34
2024-08-16T03:13:45
BoostNote-App
BoostIO/BoostNote-App
3,745
398
```xml <?xml version="1.0" encoding="utf-8"?> <!-- ~ ~ ~ path_to_url ~ ~ Unless required by applicable law or agreed to in writing, software ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --> <resources> <string name="mtrl_picker_range_header_title">Vlg interval</string> <string name="mtrl_picker_date_header_title">Vlg dato</string> <string name="mtrl_picker_range_header_unselected">Startdato Slutdato</string> <string name="mtrl_picker_range_header_only_start_selected">%1$s Slutdato</string> <string name="mtrl_picker_range_header_only_end_selected">Startdato %1$s</string> <string name="mtrl_picker_range_header_selected">%1$s %2$s</string> <string name="mtrl_picker_date_header_unselected">Valgt dato</string> <string name="mtrl_picker_date_header_selected">%1$s</string> <string name="mtrl_picker_confirm">OK</string> <string name="mtrl_picker_cancel">Annuller</string> <string name="mtrl_picker_text_input_date_hint">Dato</string> <string name="mtrl_picker_text_input_date_range_start_hint">Startdato</string> <string name="mtrl_picker_text_input_date_range_end_hint">Slutdato</string> <string name="mtrl_picker_text_input_year_abbr"></string> <string name="mtrl_picker_text_input_month_abbr">m</string> <string name="mtrl_picker_text_input_day_abbr">d</string> <string name="mtrl_picker_save">Gem</string> <string name="mtrl_picker_invalid_range">Ugyldigt interval.</string> <string name="mtrl_picker_out_of_range">Uden for interval: %1$s</string> <string name="mtrl_picker_invalid_format">Ugyldigt format.</string> <string name="mtrl_picker_invalid_format_use">Brug: %1$s</string> <string name="mtrl_picker_invalid_format_example">Eksempel: %1$s</string> <string name="mtrl_picker_toggle_to_calendar_input_mode">Skift til input-tilstand for kalender</string> <string name="mtrl_picker_toggle_to_text_input_mode">Skift til input-tilstand for tekst</string> <string name="mtrl_picker_a11y_prev_month">Skift til forrige mned</string> <string name="mtrl_picker_a11y_next_month">Skift til nste mned</string> <string name="mtrl_picker_toggle_to_year_selection">Tryk for at skifte til rsvisning</string> <string name="mtrl_picker_toggle_to_day_selection">Tryk for at skifte til kalendervisning</string> <string name="mtrl_picker_day_of_week_column_header">%1$s</string> <string name="mtrl_picker_announce_current_selection">Aktuelt valg: %1$s</string> <string name="mtrl_picker_announce_current_range_selection">Valg af startdato: %1$s Valg af slutdato: %2$s</string> <string name="mtrl_picker_announce_current_selection_none">ingen</string> <string name="mtrl_picker_navigate_to_year_description">G til r %1$d</string> <string name="mtrl_picker_navigate_to_current_year_description">G til indevrende r %1$d</string> <string name="mtrl_picker_today_description">I dag %1$s</string> <string name="mtrl_picker_start_date_description">Startdato %1$s</string> <string name="mtrl_picker_end_date_description">Slutdato %1$s</string> </resources> ```
/content/code_sandbox/lib/java/com/google/android/material/datepicker/res/values-da/strings.xml
xml
2016-12-05T16:11:29
2024-08-16T17:51:42
material-components-android
material-components/material-components-android
16,176
854
```xml <?xml version="1.0" encoding="UTF-8"?> <definitions xmlns="path_to_url" xmlns:activiti="path_to_url" targetNamespace="Examples"> <process id="simpleParallelGateway"> <startEvent id="theStart" /> <sequenceFlow id="flow1" sourceRef="theStart" targetRef="fork" /> <parallelGateway id="fork" /> <sequenceFlow id="flow2" sourceRef="fork" targetRef="taskA" /> <sequenceFlow id="flow3" sourceRef="fork" targetRef="taskC" /> <sequenceFlow id="flow4" sourceRef="fork" targetRef="nestedFork" /> <userTask id="taskA" name="Task a" activiti:assignee="kermit" /> <sequenceFlow id="flow5" sourceRef="taskA" targetRef="join" /> <parallelGateway id="nestedFork" /> <sequenceFlow id="flow6" sourceRef="nestedFork" targetRef="taskB1" /> <sequenceFlow id="flow7" sourceRef="nestedFork" targetRef="taskB2" /> <userTask id="taskB1" name="Task b1" activiti:assignee="kermit" /> <sequenceFlow id="flow8" sourceRef="taskB1" targetRef="nestedJoin" /> <userTask id="taskB2" name="Task b2" activiti:assignee="kermit" /> <sequenceFlow id="flow9" sourceRef="taskB2" targetRef="nestedJoin" /> <parallelGateway id="nestedJoin" /> <sequenceFlow id="flow10" sourceRef="nestedJoin" targetRef="join" /> <userTask id="taskC" name="Task c" activiti:assignee="fozzie" /> <sequenceFlow id="flow11" sourceRef="taskC" targetRef="join" /> <parallelGateway id="join" /> <sequenceFlow id="flow12" sourceRef="join" targetRef="theEnd" /> <endEvent id="theEnd" /> </process> </definitions> ```
/content/code_sandbox/modules/flowable-engine/src/test/resources/org/flowable/engine/test/api/v6/Flowable6Test.testSimpleNestedParallelGateway.bpmn20.xml
xml
2016-10-13T07:21:43
2024-08-16T15:23:14
flowable-engine
flowable/flowable-engine
7,715
491
```xml /* * @license Apache-2.0 * * * * path_to_url * * Unless required by applicable law or agreed to in writing, software * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */ // TypeScript Version: 4.1 /// <reference types="@stdlib/types"/> import { Array1D, Array2D } from '@stdlib/types/array'; import { Shape1D, Shape2D } from '@stdlib/types/ndarray'; /** * Binary callback. * * @param v1 - element from first input array * @param v2 - element from second input array * @returns result */ type Binary<T, U, V> = ( v1: T, v2: U ) => V; /** * Input array. */ type InputArray<T> = Array1D<T> | Array2D<T>; /** * Input array shape. */ type InputArrayShape = Shape1D | Shape2D; /** * Output array. */ type OutputArray<T> = Array2D<T>; /** * Output array shape. */ type OutputArrayShape = Shape2D; /** * Input and output arrays. */ type InOutArrays<T, U, V> = [ InputArray<T>, InputArray<U>, OutputArray<V> ]; /** * Input and output array shapes. */ type InOutShapes = [ InputArrayShape, InputArrayShape, OutputArrayShape ]; /** * Applies a binary callback to elements in two broadcasted input arrays and assigns results to elements in a two-dimensional nested output array. * * ## Notes * * - The input array shapes must be broadcast compatible with the output array shape. * * @param arrays - array containing two input nested arrays and one output nested array * @param shapes - array shapes * @param fcn - binary callback * * @example * var ones2d = require( '@stdlib/array/base/ones2d' ); * var zeros2d = require( '@stdlib/array/base/zeros2d' ); * var add = require( '@stdlib/math/base/ops/add' ); * * var shapes = [ * [ 1, 2 ], * [ 2, 1 ], * [ 2, 2 ] * ]; * * var x = ones2d( shapes[ 0 ] ); * var y = ones2d( shapes[ 1 ] ); * var z = zeros2d( shapes[ 2 ] ); * * bbinary2d( [ x, y, z ], shapes, add ); * * console.log( z ); * // => [ [ 2.0, 2.0 ], [ 2.0, 2.0 ] ] */ declare function bbinary2d<T = unknown, U = unknown, V = unknown>( arrays: InOutArrays<T, U, V>, shapes: InOutShapes, fcn: Binary<T, U, V> ): void; // EXPORTS // export = bbinary2d; ```
/content/code_sandbox/lib/node_modules/@stdlib/array/base/broadcasted-binary2d/docs/types/index.d.ts
xml
2016-03-24T04:19:52
2024-08-16T09:03:19
stdlib
stdlib-js/stdlib
4,266
628
```xml <?xml version="1.0" encoding="utf-8"?> <LinearLayout xmlns:android="path_to_url" android:orientation="vertical" android:layout_width="match_parent" android:layout_height="wrap_content" android:paddingLeft="16dp" android:paddingStart="16dp" android:paddingRight="22dp" android:paddingEnd="22dp"> <TextView android:id="@android:id/summary" android:layout_width="wrap_content" android:layout_height="wrap_content" android:textStyle="italic" android:textSize="12sp" /> </LinearLayout> ```
/content/code_sandbox/app/src/main/res/layout/prefs_disclaimer.xml
xml
2016-02-01T23:48:36
2024-08-15T03:35:42
TagMo
HiddenRamblings/TagMo
2,976
136
```xml <?xml version="1.0" encoding="utf-8"?> <androidx.core.widget.NestedScrollView xmlns:android="path_to_url" xmlns:app="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent" app:layout_behavior="@string/appbar_scrolling_view_behavior"> <LinearLayout android:id="@+id/chat_contact_properties_options" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_marginBottom="8dp" android:orientation="vertical"> <include android:id="@+id/call_in_progress" layout="@layout/item_call_in_progress_layout" android:layout_width="match_parent" android:layout_height="48dp" /> <!-- CONTACT INFO LAYOUT --> <LinearLayout android:id="@+id/chat_contact_properties_info_options_layout" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical" android:paddingStart="72dp" android:paddingTop="14dp"> <mega.privacy.android.app.components.twemoji.EmojiTextView android:id="@+id/name_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="52dp" android:maxLines="1" android:textAppearance="@style/TextAppearance.Mega.Subtitle1" app:emojiSize="14sp" /> <TextView android:id="@+id/email_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="52dp" android:ellipsize="end" android:maxLines="2" android:textAppearance="@style/TextAppearance.Mega.Subtitle2.Normal" /> <TextView android:id="@+id/nickname_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginTop="15dp" android:layout_marginEnd="52dp" android:layout_marginBottom="7dp" android:ellipsize="end" android:maxLines="2" android:paddingTop="10dp" android:paddingBottom="10dp" android:text="@string/add_nickname" android:textAppearance="@style/TextAppearance.Mega.Subtitle2" android:textColor="?attr/colorSecondary" /> </LinearLayout> <View android:id="@+id/divider_info_options_layout" android:layout_width="match_parent" android:layout_height="1dp" android:background="@color/grey_012_white_012" /> <!-- CHAT ACTIONS LAYOUT --> <LinearLayout android:id="@+id/chat_options_layout" android:layout_width="match_parent" android:layout_height="64dp" android:layout_marginTop="8dp" android:orientation="horizontal"> <RelativeLayout android:id="@+id/send_chat_message_layout" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_weight="1" android:gravity="center"> <RelativeLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center"> <ImageView android:id="@+id/chat_contact_properties_send_message_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:layout_marginBottom="8dp" android:src="@drawable/ic_chat_outline" app:tint="?attr/colorSecondary" /> <TextView android:id="@+id/chat_contact_properties_send_message_label" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/chat_contact_properties_send_message_icon" android:layout_centerHorizontal="true" android:ellipsize="end" android:maxLines="1" android:text="@string/message_button" android:textColor="?android:attr/textColorPrimary" android:textSize="12sp" /> </RelativeLayout> </RelativeLayout> <RelativeLayout android:id="@+id/chat_audio_call_layout" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_weight="1" android:gravity="center"> <RelativeLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center"> <ImageView android:id="@+id/chat_contact_properties_call_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:layout_marginBottom="8dp" android:src="@drawable/ic_phone" app:tint="?attr/colorSecondary" /> <TextView android:id="@+id/chat_contact_properties_call_label" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/chat_contact_properties_call_icon" android:layout_centerHorizontal="true" android:ellipsize="end" android:maxLines="1" android:text="@string/call_button" android:textColor="?android:attr/textColorPrimary" android:textSize="12sp" /> </RelativeLayout> </RelativeLayout> <RelativeLayout android:id="@+id/chat_video_call_layout" android:layout_width="match_parent" android:layout_height="match_parent" android:layout_weight="1" android:gravity="center"> <RelativeLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="center"> <ImageView android:id="@+id/chat_contact_properties_video_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerHorizontal="true" android:layout_marginBottom="8dp" android:src="@drawable/ic_video_outline" app:tint="?attr/colorSecondary" /> <TextView android:id="@+id/chat_contact_properties_video_label" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/chat_contact_properties_video_icon" android:layout_centerHorizontal="true" android:ellipsize="end" android:maxLines="1" android:text="@string/video_button" android:textColor="?android:attr/textColorPrimary" android:textSize="12sp" /> </RelativeLayout> </RelativeLayout> </LinearLayout> <View android:id="@+id/divider_chat_options_layout" android:layout_width="fill_parent" android:layout_height="1dp" android:background="@color/grey_012_white_012" /> <!-- INCOMING SHARED FOLDERS LAYOUT --> <RelativeLayout android:id="@+id/shared_folders_layout" android:layout_width="match_parent" android:layout_height="56dp" android:layout_gravity="start|center_vertical"> <ImageView android:id="@+id/chat_contact_properties_incoming_shares_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentStart="true" android:layout_alignParentTop="true" android:layout_alignParentBottom="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="16dp" android:layout_marginEnd="16dp" android:src="@drawable/ic_incoming_share" app:tint="?android:attr/textColorSecondary" /> <TextView android:id="@+id/chat_contact_properties_shared_folders_label" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_toEndOf="@+id/chat_contact_properties_incoming_shares_icon" android:layout_marginStart="16dp" android:text="@string/title_incoming_shares_explorer" android:textAppearance="@style/TextAppearance.Mega.Body1.Variant3" /> <Button android:id="@+id/share_folders_button" style="?attr/borderlessButtonStyle" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_alignParentEnd="true" android:layout_centerVertical="true" android:layout_marginEnd="16dp" android:minWidth="0dp" /> </RelativeLayout> <RelativeLayout android:id="@+id/shared_folder_list_container" android:layout_width="fill_parent" android:layout_height="wrap_content" android:visibility="gone"> <FrameLayout android:id="@+id/fragment_container_shared_folders" android:layout_width="match_parent" android:layout_height="wrap_content" /> </RelativeLayout> <View android:id="@+id/divider_shared_folder_layout" android:layout_width="fill_parent" android:layout_height="1dp" android:layout_marginStart="72dp" android:background="@color/grey_012_white_012" /> <!-- NOTIFICATIONS LAYOUT --> <LinearLayout android:id="@+id/notifications_layout" android:layout_width="match_parent" android:layout_height="56dp" android:orientation="horizontal"> <ImageView android:id="@+id/chat_contact_properties_chat_notification_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="start|center_vertical" android:layout_marginStart="16dp" android:layout_marginEnd="16dp" android:src="@drawable/ic_bell" app:tint="?android:attr/textColorSecondary" /> <RelativeLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="16dp" android:layout_gravity="center"> <TextView android:id="@+id/notifications_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="start|center_vertical" android:text="@string/title_properties_chat_notifications_contact" android:textAppearance="@style/TextAppearance.Mega.Body1.Variant3" /> <TextView android:id="@+id/notifications_muted_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_below="@id/notifications_text" android:layout_gravity="start|center_vertical" android:textAppearance="@style/TextAppearance.Mega.Body2.Secondary" /> </RelativeLayout> <RelativeLayout android:id="@+id/notification_switch_layout" android:layout_width="0dp" android:layout_height="match_parent" android:layout_gravity="center_vertical" android:layout_weight="1" android:gravity="end|center_vertical"> <mega.privacy.android.shared.original.core.ui.controls.controlssliders.MegaSwitch android:id="@+id/notification_switch" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="16dp" android:clickable="false" /> </RelativeLayout> </LinearLayout> <View android:id="@+id/divider_notifications_layout" android:layout_width="match_parent" android:layout_height="1dp" android:layout_marginStart="72dp" android:background="@color/grey_012_white_012" /> <!-- SHARE CONTACT LAYOUT --> <RelativeLayout android:id="@+id/share_contact_layout" android:layout_width="match_parent" android:layout_height="56dp" android:layout_gravity="start|center_vertical"> <ImageView android:id="@+id/chat_contact_properties_share_contact_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="16dp" android:src="@drawable/ic_contact_share" app:tint="?android:attr/textColorSecondary" /> <TextView android:id="@+id/chat_contact_properties_share_contact" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="32dp" android:layout_toEndOf="@id/chat_contact_properties_share_contact_icon" android:text="@string/title_properties_chat_share_contact" android:textAppearance="@style/TextAppearance.Mega.Body1.Variant3" /> </RelativeLayout> <View android:id="@+id/divider_share_contact_layout" android:layout_width="match_parent" android:layout_height="1dp" android:layout_marginStart="72dp" android:background="@color/grey_012_white_012" /> <!-- VERIFY CREDENTIALS LAYOUT --> <RelativeLayout android:id="@+id/verify_credentials_layout" android:layout_width="match_parent" android:layout_height="72dp" android:layout_gravity="start|center_vertical" android:visibility="gone"> <ImageView android:id="@+id/chat_contact_properties_verify_credentials_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="start|center_vertical" android:layout_marginStart="16dp" android:layout_marginTop="16dp" android:src="@drawable/ic_verify_credential" app:tint="?android:attr/textColorPrimary" /> <RelativeLayout android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_marginStart="32dp" android:layout_toEndOf="@id/chat_contact_properties_verify_credentials_icon"> <TextView android:id="@+id/chat_contact_properties_verify_credentials" android:layout_width="wrap_content" android:layout_height="wrap_content" android:text="@string/contact_approve_credentials_toolbar_title" android:textAppearance="@style/TextAppearance.Mega.Body1.Variant3" /> <RelativeLayout android:id="@+id/chat_contact_properties_verify_credentials_info_layout" android:layout_width="match_parent" android:layout_height="24dp" android:layout_below="@+id/chat_contact_properties_verify_credentials"> <ImageView android:id="@+id/verify_credentials_info_icon" android:layout_width="24dp" android:layout_height="24dp" android:layout_marginEnd="8dp" android:src="@drawable/ic_contact_verified" /> <TextView android:id="@+id/verify_credentials_info" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_toEndOf="@+id/verify_credentials_info_icon" android:text="@string/contact_verify_credentials_not_verified_text" android:textAppearance="@style/TextAppearance.Mega.Body2.Secondary" /> </RelativeLayout> </RelativeLayout> <View android:id="@+id/divider_verify_credentials_layout" android:layout_width="match_parent" android:layout_height="1dp" android:layout_alignParentBottom="true" android:layout_marginStart="72dp" android:background="@color/grey_012_white_012" /> </RelativeLayout> <!-- SHARED FILES LAYOUT --> <RelativeLayout android:id="@+id/chat_files_shared_layout" android:layout_width="match_parent" android:layout_height="56dp" android:layout_gravity="start|center_vertical"> <ImageView android:id="@+id/chat_contact_properties_chat_files_shared_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="16dp" android:src="@drawable/ic_shared_files" app:tint="?android:attr/textColorSecondary" /> <TextView android:id="@+id/chat_files_shared" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="32dp" android:layout_toEndOf="@id/chat_contact_properties_chat_files_shared_icon" android:text="@string/title_chat_shared_files_info" android:textAppearance="@style/TextAppearance.Mega.Body1.Variant3" /> </RelativeLayout> <View android:id="@+id/divider_chat_files_shared_layout" android:layout_width="match_parent" android:layout_height="1dp" android:layout_marginStart="72dp" android:background="@color/grey_012_white_012" /> <!-- CLEAR LAYOUT --> <RelativeLayout android:id="@+id/contact_properties_layout" android:layout_width="match_parent" android:layout_height="wrap_content" android:layout_gravity="start|center_vertical" android:minHeight="56dp" android:paddingTop="17dp" android:paddingBottom="15dp"> <RelativeLayout android:id="@+id/manage_chat_history_layout" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="20dp"> <ImageView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_gravity="start|center_vertical" android:layout_marginEnd="32dp" android:src="@drawable/ic_clear_chat_history" app:tint="?android:attr/textColorSecondary" android:contentDescription="@string/title_properties_manage_chat" /> <TextView android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginStart="52dp" android:layout_marginEnd="56dp" android:text="@string/title_properties_manage_chat" android:textAppearance="@style/TextAppearance.Mega.Body1.Variant3" /> </RelativeLayout> <TextView android:id="@+id/retention_time_text" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginEnd="56dp" android:layout_below="@id/manage_chat_history_layout" android:layout_centerVertical="true" android:layout_marginStart="72dp" android:textAppearance="@style/TextAppearance.Mega.Body2.Secondary" android:visibility="gone" /> </RelativeLayout> <View android:id="@+id/divider_chat_history_layout" android:layout_width="match_parent" android:layout_height="1dp" android:layout_marginStart="72dp" android:background="@color/grey_012_white_012" /> <!-- REMOVE CONTACT LAYOUT --> <RelativeLayout android:id="@+id/remove_contact_layout" android:layout_width="match_parent" android:layout_height="56dp" android:layout_gravity="left|center_vertical"> <ImageView android:id="@+id/chat_contact_properties_remove_contact_icon" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="16dp" android:src="@drawable/ic_remove_contact" app:tint="@color/red_600_red_300" /> <TextView android:id="@+id/chat_contact_properties_remove_contact_label" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerVertical="true" android:layout_gravity="start|center_vertical" android:layout_marginStart="32dp" android:layout_toEndOf="@id/chat_contact_properties_remove_contact_icon" android:text="@string/title_properties_remove_contact" android:textAppearance="@style/TextAppearance.Mega.Subtitle1.Red" /> </RelativeLayout> </LinearLayout> </androidx.core.widget.NestedScrollView> ```
/content/code_sandbox/app/src/main/res/layout/content_chat_contact_properties_activity.xml
xml
2016-05-04T11:46:20
2024-08-15T16:29:10
android
meganz/android
1,537
4,383
```xml <?xml version="1.0" encoding="utf-8"?> <!-- path_to_url Unless required by applicable law or agreed to in writing, software WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --> <LinearLayout xmlns:android="path_to_url" android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" android:background="@color/bsp_blue" android:paddingLeft="@dimen/bsp_selected_calendar_layout_keyline" android:paddingStart="@dimen/bsp_selected_calendar_layout_keyline" android:paddingTop="@dimen/bsp_selected_calendar_layout_top_keyline"> <include layout="@layout/bsp_date_picker_header_view" /> <com.philliphsu.bottomsheetpickers.AccessibleLinearLayout android:id="@+id/bsp_date_picker_month_day_year" android:layout_width="match_parent" android:layout_height="wrap_content" android:orientation="vertical" > <com.philliphsu.bottomsheetpickers.AccessibleTextView android:id="@+id/bsp_date_picker_first_textview" android:layout_width="wrap_content" android:layout_height="wrap_content" android:includeFontPadding="false" android:textColor="@color/bsp_date_picker_selector" android:textSize="@dimen/bsp_selected_date_month_size" /> <com.philliphsu.bottomsheetpickers.AccessibleTextView android:id="@+id/bsp_date_picker_second_textview" android:layout_width="wrap_content" android:layout_height="wrap_content" android:includeFontPadding="false" android:textColor="@color/bsp_date_picker_selector" android:textSize="@dimen/bsp_selected_date_month_size" /> </com.philliphsu.bottomsheetpickers.AccessibleLinearLayout> </LinearLayout> ```
/content/code_sandbox/bottomsheetpickers/src/main/res/layout-land/bsp_date_picker_selected_date.xml
xml
2016-10-06T01:20:05
2024-08-05T10:12:07
BottomSheetPickers
philliphsu/BottomSheetPickers
1,101
398
```xml import { StyleSheet, Text, View } from 'react-native'; import * as <%- project.name %> from '<%- project.slug %>'; export default function App() { return ( <View style={styles.container}> <Text>{<%- project.name %>.hello()}</Text> </View> ); } const styles = StyleSheet.create({ container: { flex: 1, backgroundColor: '#fff', alignItems: 'center', justifyContent: 'center', }, }); ```
/content/code_sandbox/packages/expo-module-template/example/App.tsx
xml
2016-08-15T17:14:25
2024-08-16T19:54:44
expo
expo/expo
32,004
104
```xml import "../../utils/test-setup" import { createTestingConnections, closeTestingConnections, reloadTestingDatabases, } from "../../utils/test-utils" import { DataSource } from "../../../src" import { expect } from "chai" describe("github issues > #9063 Support postgres column with varchar datatype and uuid_generate_v4() default", () => { let connections: DataSource[] before( async () => (connections = await createTestingConnections({ entities: [__dirname + "/entity/*{.js,.ts}"], enabledDrivers: ["postgres"], schemaCreate: true, dropSchema: true, })), ) beforeEach(() => reloadTestingDatabases(connections)) after(() => closeTestingConnections(connections)) it("it should be able to set special keyword as column name for simple-enum types", () => Promise.all( connections.map(async (connection) => { const queryRunner = connection.createQueryRunner() const table = await queryRunner.getTable("post") const generatedUuid1 = table!.findColumnByName("generatedUuid1")! const generatedUuid2 = table!.findColumnByName("generatedUuid2")! const generatedUuid3 = table!.findColumnByName("generatedUuid3")! const nonGeneratedUuid1 = table!.findColumnByName("nonGeneratedUuid1")! const nonGeneratedUuid2 = table!.findColumnByName("nonGeneratedUuid2")! expect(generatedUuid1.isGenerated).to.be.true expect(generatedUuid1.type).to.equal("uuid") expect(generatedUuid1.default).to.be.undefined expect(generatedUuid2.isGenerated).to.be.true expect(generatedUuid2.type).to.equal("uuid") expect(generatedUuid2.default).to.be.undefined expect(generatedUuid3.isGenerated).to.be.true expect(generatedUuid3.type).to.equal("uuid") expect(generatedUuid3.default).to.be.undefined expect(nonGeneratedUuid1.isGenerated).to.be.false expect(nonGeneratedUuid1.type).to.equal("character varying") expect(nonGeneratedUuid1.default).to.equal("uuid_generate_v4()") expect(nonGeneratedUuid2.isGenerated).to.be.false expect(nonGeneratedUuid2.type).to.equal("character varying") expect(nonGeneratedUuid2.default).to.equal("gen_random_uuid()") await queryRunner.release() }), )) }) ```
/content/code_sandbox/test/github-issues/9063/issue-9063.ts
xml
2016-02-29T07:41:14
2024-08-16T18:28:52
typeorm
typeorm/typeorm
33,875
517
```xml <?xml version="1.0" encoding="utf-8"?> <layout xmlns:android="path_to_url" xmlns:tools="path_to_url" > <data> <variable name="handlers" type="com.github.yuweiguocn.demo.greendao.about.AboutClickHandlers"/> <variable name="about" type="com.github.yuweiguocn.demo.greendao.bean.About"/> <import type="android.text.Html"/> </data> <LinearLayout android:layout_width="match_parent" android:layout_height="match_parent" android:orientation="vertical" tools:context=".ui.about.AboutActivity"> <include android:id="@+id/include_toolbar" layout="@layout/view_toolbar"/> <TextView android:layout_marginTop="@dimen/activity_vertical_margin" android:text="@string/contact_me" style="@style/TextStyle" android:textSize="24sp" /> <TextView android:layout_marginTop="@dimen/activity_vertical_margin" android:onClick="@{handlers::onClickGitHub}" android:text="@{Html.fromHtml(about.github)}" style="@style/TextStyle" /> <TextView android:onClick="@{handlers::onClickWeibo}" android:text="@{Html.fromHtml(about.weibo)}" style="@style/TextStyle" /> <TextView style="@style/TextStyle" android:text="@{Html.fromHtml(about.email)}" /> <TextView android:onClick="@{handlers::onClickBlog}" android:text="@{Html.fromHtml(about.blog)}" style="@style/TextStyle" /> <TextView android:onClick="@{handlers::onClickJianshu}" android:text="@{Html.fromHtml(about.jianshu)}" style="@style/TextStyle" /> </LinearLayout> </layout> ```
/content/code_sandbox/app/src/main/res/layout/activity_about.xml
xml
2016-01-04T07:18:02
2024-08-07T09:21:10
GreenDaoUpgradeHelper
yuweiguocn/GreenDaoUpgradeHelper
1,533
416
```xml export * from './server.enum'; export * from './log.enum'; export * from './ipc.enum'; ```
/content/code_sandbox/packages/shared/src/enums/index.ts
xml
2016-05-14T02:18:49
2024-08-16T02:46:28
ElectroCRUD
garrylachman/ElectroCRUD
1,538
22
```xml import {cleanObject} from "@tsed/core"; import {OpenSpecInfo} from "@tsed/openspec"; /** * @ignore * @param info */ export function mapOpenSpecInfo(info: Partial<OpenSpecInfo>): OpenSpecInfo { const {title, description, version, termsOfService, contact, license} = info; return cleanObject({ version, title, description, termsOfService, contact, license }); } ```
/content/code_sandbox/packages/specs/schema/src/utils/mapOpenSpecInfo.ts
xml
2016-02-21T18:38:47
2024-08-14T21:19:48
tsed
tsedio/tsed
2,817
103
```xml <?xml version="1.0" encoding="utf-8"?> <Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="path_to_url"> <ItemGroup Label="ProjectConfigurations"> <ProjectConfiguration Include="Debug|Win32"> <Configuration>Debug</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Release|Win32"> <Configuration>Release</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Debug|x64"> <Configuration>Debug</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Release|x64"> <Configuration>Release</Configuration> <Platform>x64</Platform> </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Globals"> <ProjectGuid>{747CF49E-27D8-4C5E-BB46-25779FD8DDEB}</ProjectGuid> <Keyword>Win32Proj</Keyword> <RootNamespace>tut3</RootNamespace> <WindowsTargetPlatformVersion>8.1</WindowsTargetPlatformVersion> </PropertyGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>true</UseDebugLibraries> <PlatformToolset>v140</PlatformToolset> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v140</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>true</UseDebugLibraries> <PlatformToolset>v140</PlatformToolset> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'" Label="Configuration"> <ConfigurationType>Application</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v140</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> <ImportGroup Label="ExtensionSettings"> </ImportGroup> <ImportGroup Label="Shared"> </ImportGroup> <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="..\common.props" /> </ImportGroup> <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="..\common.props" /> </ImportGroup> <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="..\common.props" /> </ImportGroup> <ImportGroup Label="PropertySheets" Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="..\common.props" /> </ImportGroup> <PropertyGroup Label="UserMacros" /> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> <LinkIncremental>true</LinkIncremental> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <LinkIncremental>true</LinkIncremental> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> <LinkIncremental>false</LinkIncremental> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> <LinkIncremental>false</LinkIncremental> </PropertyGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|Win32'"> <ClCompile> <PrecompiledHeader> </PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>Disabled</Optimization> <PreprocessorDefinitions>WIN32;_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <SDLCheck>true</SDLCheck> </ClCompile> <Link> <SubSystem>Console</SubSystem> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> <PostBuildEvent> <Command>"$(TargetDir)\$(TargetName).exe" .</Command> </PostBuildEvent> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Debug|x64'"> <ClCompile> <PrecompiledHeader> </PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>Disabled</Optimization> <PreprocessorDefinitions>_DEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <SDLCheck>true</SDLCheck> </ClCompile> <Link> <SubSystem>Console</SubSystem> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> <PostBuildEvent> <Command>"$(TargetDir)\$(TargetName).exe" .</Command> </PostBuildEvent> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|Win32'"> <ClCompile> <WarningLevel>Level3</WarningLevel> <PrecompiledHeader> </PrecompiledHeader> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>WIN32;NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <SDLCheck>true</SDLCheck> </ClCompile> <Link> <SubSystem>Console</SubSystem> <GenerateDebugInformation>true</GenerateDebugInformation> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> </Link> <PostBuildEvent> <Command>"$(TargetDir)\$(TargetName).exe" .</Command> </PostBuildEvent> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Release|x64'"> <ClCompile> <WarningLevel>Level3</WarningLevel> <PrecompiledHeader> </PrecompiledHeader> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>NDEBUG;_CONSOLE;%(PreprocessorDefinitions)</PreprocessorDefinitions> <SDLCheck>true</SDLCheck> </ClCompile> <Link> <SubSystem>Console</SubSystem> <GenerateDebugInformation>true</GenerateDebugInformation> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> </Link> <PostBuildEvent> <Command>"$(TargetDir)\$(TargetName).exe" .</Command> </PostBuildEvent> </ItemDefinitionGroup> <ItemGroup> <ClCompile Include="..\..\tut3.cpp" /> </ItemGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> <ImportGroup Label="ExtensionTargets"> </ImportGroup> </Project> ```
/content/code_sandbox/deps/boost_1_66_0/libs/filesystem/example/msvc/tut3/tut3.vcxproj
xml
2016-09-05T10:18:44
2024-08-11T13:21:40
LiquidCore
LiquidPlayer/LiquidCore
1,010
1,915
```xml import { PluginFunctions } from '@draft-js-plugins/editor'; import { ContentBlock, ContentState, EditorState, SelectionState, } from 'draft-js'; import createFocusPlugin from '../index'; const mockCreateBlockKeyStore = jest.requireActual( '../utils/createBlockKeyStore' ); jest.mock('linaria'); let mockBlockKeyStore = { add: jest.fn(), remove: jest.fn(), includes: jest.fn(), getAll: jest.fn(), }; jest.mock('../utils/createBlockKeyStore', () => ({ __esModule: true, default: () => mockBlockKeyStore, })); describe('FocusPlugin', () => { beforeEach(() => { mockBlockKeyStore = mockCreateBlockKeyStore.default(); }); afterEach(() => { jest.resetAllMocks(); jest.resetModules(); }); const createEditorStateFromBlocks = (): EditorState => { const block1 = new ContentBlock({ key: 'non-selected-block', text: ' ', type: 'atomic', }); const block2 = new ContentBlock({ key: 'selected-block', text: ' ', type: 'atomic', }); const contentState = ContentState.createFromBlockArray([block1, block2]); const selectionAtEnd = SelectionState.createEmpty(block2.getKey()).merge({ focusOffset: block2.getText().length, anchorOffset: block2.getText().length, }); const editorState = EditorState.createWithContent(contentState); return EditorState.forceSelection(editorState, selectionAtEnd); }; const allowSelectedBlockToBeFocusable = (editorState: EditorState): void => { const selectionBlockKey = editorState.getSelection().getAnchorKey(); const content = editorState.getCurrentContent(); const blockKey = content.getBlockForKey(selectionBlockKey).getKey(); mockBlockKeyStore.add(blockKey); }; it('instantiates plugin', () => { const focusPlugin = createFocusPlugin(); expect(focusPlugin).toBeTruthy(); }); describe('handleKeyCommand', () => { it('should return `not-handled` when the selected block is not focusable', async () => { const setEditorState = jest.fn(); const editorState = createEditorStateFromBlocks(); const { handleKeyCommand } = createFocusPlugin(); const result = handleKeyCommand?.('delete', editorState, Date.now(), { setEditorState, } as unknown as PluginFunctions); expect(result).toEqual('not-handled'); }); it('should return `not-handled` when the command is not a delete command', async () => { const setEditorState = jest.fn(); const editorState = createEditorStateFromBlocks(); allowSelectedBlockToBeFocusable(editorState); const { handleKeyCommand } = createFocusPlugin(); const result = handleKeyCommand?.('unknown', editorState, Date.now(), { setEditorState, } as unknown as PluginFunctions); expect(result).toEqual('not-handled'); }); it('should should return `handled` when a delete command is fired on a selectable block', async () => { const setEditorState = jest.fn(); const editorState = createEditorStateFromBlocks(); allowSelectedBlockToBeFocusable(editorState); const { handleKeyCommand } = createFocusPlugin(); const result = handleKeyCommand?.('delete', editorState, Date.now(), { setEditorState, } as unknown as PluginFunctions); expect(result).toEqual('handled'); }); it('should remove the selected block from the new state when a delete command is fired', async () => { const editorState = createEditorStateFromBlocks(); allowSelectedBlockToBeFocusable(editorState); const { handleKeyCommand } = createFocusPlugin(); const setEditorState = jest.fn(); handleKeyCommand?.('delete', editorState, Date.now(), { setEditorState, } as unknown as PluginFunctions); expect(setEditorState).toHaveBeenCalled(); const nextEditorState = setEditorState.mock.calls[0][0]; expect( nextEditorState.getCurrentContent().getBlockForKey('selected-block') ).toBeUndefined(); }); it('should not update the editor state when the space command is fired', async () => { const editorState = createEditorStateFromBlocks(); allowSelectedBlockToBeFocusable(editorState); const { handleKeyCommand } = createFocusPlugin(); const setEditorState = jest.fn(); handleKeyCommand?.('space', editorState, Date.now(), { setEditorState, } as unknown as PluginFunctions); expect(setEditorState).not.toHaveBeenCalled(); }); }); describe('keyBindingFn', () => { it('should catch the space key and return undefined', async () => { const editorState = createEditorStateFromBlocks(); allowSelectedBlockToBeFocusable(editorState); const { keyBindingFn } = createFocusPlugin(); const setEditorState = jest.fn(); const evt = new KeyboardEvent('keydown', { keyCode: 32, }); // @ts-ignore const result = keyBindingFn?.(evt, { setEditorState, getEditorState: () => editorState, }); expect(result).toEqual('space'); }); }); }); ```
/content/code_sandbox/packages/focus/src/__test__/index.test.ts
xml
2016-02-26T09:54:56
2024-08-16T18:16:31
draft-js-plugins
draft-js-plugins/draft-js-plugins
4,087
1,138
```xml import type { InjectionKey } from 'vue' import type { RouteLocationNormalizedLoaded } from 'vue-router' export interface LayoutMeta { isCurrent: (route: RouteLocationNormalizedLoaded) => boolean } export const LayoutMetaSymbol: InjectionKey<LayoutMeta> = Symbol('layout-meta') export const PageRouteSymbol: InjectionKey<RouteLocationNormalizedLoaded> = Symbol('route') ```
/content/code_sandbox/packages/nuxt/src/app/components/injections.ts
xml
2016-10-26T11:18:47
2024-08-16T19:32:46
nuxt
nuxt/nuxt
53,705
81
```xml import { ComponentProps, SyntheticEvent } from 'react'; import { MYC_API } from '@config'; import { getCoinGeckoAssetManifest, useSelector } from '@store'; import { TUuid } from '@types'; import Box from './Box'; import { getSVGIcon } from './Icon'; const baseURL = `${MYC_API}/images`; function buildUrl(uuid: TUuid) { return `${baseURL}/${uuid}.png`; } function getIconUrl(uuid: TUuid, assetIconsManifest?: TUuid[]) { const assetIconExists = assetIconsManifest && assetIconsManifest.includes(uuid); return assetIconExists ? buildUrl(uuid) : getSVGIcon('generic-asset-icon'); } interface Props { uuid: TUuid; size?: string; className?: string; } const AssetIcon = ({ uuid, size, ...props }: Props & ComponentProps<typeof Box>) => { const coinGeckoAssetManifest = useSelector(getCoinGeckoAssetManifest); const iconUrl = getIconUrl(uuid, coinGeckoAssetManifest); // Replace src in the eventuality the server fails to reply with the requested icon. const handleError = (event: SyntheticEvent<HTMLImageElement, Event>) => { const elem = event.currentTarget; elem.onerror = null; elem.src = getSVGIcon('generic-asset-icon'); }; return ( <Box display="inline-flex" height={size} width={size} {...props}> <img src={iconUrl} onError={handleError} /> </Box> ); }; export default AssetIcon; ```
/content/code_sandbox/src/components/AssetIcon.tsx
xml
2016-12-04T01:35:27
2024-08-14T21:41:58
MyCrypto
MyCryptoHQ/MyCrypto
1,347
331
```xml <?xml version="1.0" encoding="utf-8"?> <resources> <string-array name="sort_options"> <item></item> <item></item> <item> </item> <item> </item> </string-array> <string-array name="sort_options_images"> <item> </item> <item> </item> <item> </item> <item> </item> </string-array> <string-array name="filter_options_history"> <item></item> <item></item> <item></item> <item></item> <item></item> <item></item> <item></item> <item></item> </string-array> </resources> ```
/content/code_sandbox/app/src/main/res/values-zh/arrays.xml
xml
2016-02-22T10:00:46
2024-08-16T15:37:50
Images-to-PDF
Swati4star/Images-to-PDF
1,174
169
```xml import React, { FunctionComponent } from "react"; const ListBulletsIcon: FunctionComponent = () => { // path_to_url return ( <svg xmlns="path_to_url" viewBox="-0.25 -0.25 24.5 24.5"> <g> <circle cx="3" cy="3" r="2.25" fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" ></circle> <circle cx="3" cy="12" r="2.25" fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" ></circle> <circle cx="3" cy="21" r="2.25" fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" ></circle> <line x1="8.25" y1="3" x2="23.25" y2="3" fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" ></line> <line x1="8.25" y1="12" x2="23.25" y2="12" fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" ></line> <line x1="8.25" y1="21" x2="23.25" y2="21" fill="none" stroke="currentColor" strokeLinecap="round" strokeLinejoin="round" ></line> </g> </svg> ); }; export default ListBulletsIcon; ```
/content/code_sandbox/client/src/core/client/ui/components/icons/ListBulletsIcon.tsx
xml
2016-10-31T16:14:05
2024-08-06T16:15:57
talk
coralproject/talk
1,881
397
```xml import type { Meta, StoryObj } from '@storybook/vue3'; import Component from './reference-type-props/component.vue'; const meta = { component: Component, tags: ['autodocs'], } satisfies Meta<typeof Component>; type Story = StoryObj<typeof meta>; export default meta; enum MyEnum { Small, Medium, Large, } export const ReferenceTypeProps: Story = { args: { foo: 'Foo', baz: true, stringArray: ['Foo', 'Bar', 'Baz'], bar: 1, unionOptional: 'Foo', union: 'Foo', inlined: { foo: 'Foo' }, nested: { nestedProp: 'Nested Prop' }, nestedIntersection: { nestedProp: 'Nested Prop', additionalProp: 'Additional Prop' }, array: [{ nestedProp: 'Nested Prop' }], literalFromContext: 'Uncategorized', enumValue: MyEnum.Small, }, }; ```
/content/code_sandbox/code/renderers/vue3/template/stories_vue3-vite-default-ts/component-meta/ReferenceTypeProps.stories.ts
xml
2016-03-18T04:23:44
2024-08-16T19:22:08
storybook
storybookjs/storybook
83,755
207
```xml import { expect, fn, userEvent, within } from '@storybook/test'; import type { StoryFn as CSF2Story, Meta, StoryObj } from '../..'; import AddWrapperDecorator from './AddWrapperDecorator.svelte'; import Button from './Button.svelte'; import CustomRenderComponent from './CustomRenderComponent.svelte'; import InputFilledStoryComponent from './InputFilledStoryComponent.svelte'; import LoaderStoryComponent from './LoaderStoryComponent.svelte'; import StoryWithLocaleComponent from './StoryWithLocaleComponent.svelte'; const meta = { title: 'Example/Button', component: Button, argTypes: { backgroundColor: { control: 'color' }, size: { control: { type: 'select' }, options: ['small', 'medium', 'large'], }, }, excludeStories: /.*ImNotAStory$/, } satisfies Meta<Button>; export default meta; type CSF3Story = StoryObj<typeof meta>; // For testing purposes. Should be ignored in ComposeStories export const ImNotAStory = 123; const Template: CSF2Story = (args) => ({ Component: Button, props: args, }); export const CSF2Secondary = Template.bind({}); CSF2Secondary.args = { label: 'label coming from story args!', primary: false, }; const getCaptionForLocale = (locale: string) => { switch (locale) { case 'es': return 'Hola!'; case 'fr': return 'Bonjour!'; case 'kr': return '!'; case 'pt': return 'Ol!'; default: return 'Hello!'; } }; export const CSF2StoryWithLocale: CSF2Story<StoryWithLocaleComponent> = (args, { globals }) => ({ Component: StoryWithLocaleComponent, props: { ...args, locale: globals.locale, label: getCaptionForLocale(globals.locale), }, }); CSF2StoryWithLocale.storyName = 'WithLocale'; export const CSF2StoryWithParamsAndDecorator = Template.bind({}); CSF2StoryWithParamsAndDecorator.args = { label: 'foo', }; CSF2StoryWithParamsAndDecorator.parameters = { layout: 'centered', }; CSF2StoryWithParamsAndDecorator.decorators = [ () => ({ Component: AddWrapperDecorator, }), ]; export const NewStory: CSF3Story = { args: { label: 'foo', size: 'large', primary: true, }, decorators: [ () => ({ Component: AddWrapperDecorator, }), ], }; export const CSF3Primary: CSF3Story = { args: { label: 'foo', size: 'large', primary: true, }, }; export const CSF3Button: CSF3Story = { args: { label: 'foo' }, }; export const CSF3ButtonWithRender: StoryObj<CustomRenderComponent> = { args: { buttonProps: CSF3Button.args, }, render: (args) => ({ Component: CustomRenderComponent, props: { buttonProps: args.buttonProps, }, }), }; export const CSF3InputFieldFilled: StoryObj<InputFilledStoryComponent> = { render: () => ({ Component: InputFilledStoryComponent, }), play: async ({ canvasElement, step }) => { const canvas = within(canvasElement); await step('Step label', async () => { const inputEl = canvas.getByTestId('input'); await userEvent.type(inputEl, 'Hello world!'); await expect(inputEl).toHaveValue('Hello world!'); }); }, }; const mockFn = fn(); export const LoaderStory: StoryObj<LoaderStoryComponent> = { args: { mockFn, }, loaders: [ async () => { mockFn.mockReturnValueOnce('mockFn return value'); return { value: 'loaded data', }; }, ], render: (args, { loaded }) => ({ Component: LoaderStoryComponent, props: { ...args, loaded, }, }), play: async () => { expect(mockFn).toHaveBeenCalledWith('render'); }, }; ```
/content/code_sandbox/code/renderers/svelte/src/__test__/composeStories/Button.stories.ts
xml
2016-03-18T04:23:44
2024-08-16T19:22:08
storybook
storybookjs/storybook
83,755
908
```xml import { useRecoilValue } from "recoil"; import { v4 as uuid } from "uuid"; import { currentAppUser, currentWorkspaceState, savedFilesState, } from "../state/atoms.js"; import { useDeleteWorkspace, useLoadLocalWorkspace, useSaveNewWorkspace, } from "../state/callbacks.js"; import { logInWrapper } from "../utils/firebaseUtils.js"; import BlueButton from "./BlueButton.js"; import FileButton from "./FileButton.js"; export default function SavedFilesBrowser() { const savedFiles = useRecoilValue(savedFilesState); const currentWorkspace = useRecoilValue(currentWorkspaceState); const loadWorkspace = useLoadLocalWorkspace(); const onDelete = useDeleteWorkspace(); const saveNewWorkspace = useSaveNewWorkspace(); const useLogin = logInWrapper(); const currentUser = useRecoilValue(currentAppUser); return ( <> {currentUser != null ? ( <div> {Object.values(savedFiles) // Display most recently modified at the top .sort( (file1, file2) => file2.metadata.lastModified - file1.metadata.lastModified, ) .map((file) => ( <FileButton key={file.metadata.id} onClick={() => loadWorkspace(file.metadata.id)} isFocused={file.metadata.id === currentWorkspace.metadata.id} onDelete={() => onDelete(file.metadata)} > {file.metadata.name} </FileButton> ))} <div> {(currentWorkspace.metadata.location.kind !== "stored" || !currentWorkspace.metadata.location.saved) && ( <BlueButton onClick={() => saveNewWorkspace( currentWorkspace.metadata.id, currentWorkspace, ) } > save current workspace </BlueButton> )} {currentWorkspace.metadata.location.kind === "stored" && currentWorkspace.metadata.location.saved && ( <BlueButton onClick={() => saveNewWorkspace(uuid(), currentWorkspace)} > duplicate workspace </BlueButton> )} </div> </div> ) : ( <div style={{ margin: "0.5em" }}> <p>Please sign in to use saved diagrams!</p> <BlueButton onClick={useLogin}> Login with GitHub </BlueButton> </div> )} </> ); } ```
/content/code_sandbox/packages/editor/src/components/SavedBrowser.tsx
xml
2016-09-22T04:47:19
2024-08-16T13:00:54
penrose
penrose/penrose
6,760
502
```xml <!-- or more contributor license agreements. See the NOTICE file distributed with this work for additional information regarding copyright ownership. The ASF licenses this file path_to_url Unless required by applicable law or agreed to in writing, "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY specific language governing permissions and limitations --> <!DOCTYPE suite SYSTEM "path_to_url" > <suite name="WebSocket Integration Tests" verbose="2" annotations="JDK"> <test name="messaging-test-suite" preserve-order="true"> <classes> <class name="org.apache.pulsar.tests.integration.websocket.TestWebSocket" /> </classes> </test> </suite> ```
/content/code_sandbox/tests/integration/src/test/resources/pulsar-websocket.xml
xml
2016-06-28T07:00:03
2024-08-16T17:12:43
pulsar
apache/pulsar
14,047
151
```xml /* * @license Apache-2.0 * * * * path_to_url * * Unless required by applicable law or agreed to in writing, software * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. */ // TypeScript Version: 4.1 /** * Subtracts two single-precision floating-point numbers `x` and `y`. * * @param x - first input value * @param y - second input value * @returns result * * @example * var v = subf( -1.0, 5.0 ); * // returns -6.0 * * @example * var v = subf( 2.0, 5.0 ); * // returns -3.0 * * @example * var v = subf( 0.0, 5.0 ); * // returns -5.0 * * @example * var v = subf( -0.0, 0.0 ); * // returns -0.0 * * @example * var v = subf( NaN, NaN ); * // returns NaN */ declare function subf( x: number, y: number ): number; // EXPORTS // export = subf; ```
/content/code_sandbox/lib/node_modules/@stdlib/math/base/ops/subf/docs/types/index.d.ts
xml
2016-03-24T04:19:52
2024-08-16T09:03:19
stdlib
stdlib-js/stdlib
4,266
267
```xml import { $, comma } from '../_util'; const form = $('main > form') as HTMLFormElement; const run = $('#run'); const status = $('#status'); const stop = $('#stop'); const table = $('table'); const tbody = $('tbody'); const reduce = (acc: any, cur: any) => ({ ...acc, [cur.value]: cur.label }); const holes = [...form.hole.options].reduce(reduce, {}); const langs = [...(form.lang as any).options].reduce(reduce, {}); stop.onclick = () => alert('TODO'); form.onchange = () => history.replaceState( '', '', 'solutions?' + new URLSearchParams(new FormData(form) as any)); form.onsubmit = async e => { e.preventDefault(); const start = Date.now(); tbody.innerHTML = ''; const res = await fetch('solutions/run?' + new URLSearchParams(new FormData(form) as any)); if (!res.ok || !res.body) return; run.style.display = 'none'; stop.style.display = 'block'; table.style.display = 'table'; let buffer = ''; let failing = 0; let solutions = 0; const decoder = new TextDecoder(); const reader = res.body.getReader(); const append = (lineString: string) => { const line = JSON.parse(lineString); if (!line.pass) failing++; status.innerText = comma(++solutions) + '/' + comma(line.total) + ` solutions (${comma(failing)} failing) in ` + new Date(Date.now() - start).toISOString().substr(14, 8).replace(/^00:/, ''); const stderr = <code></code>; stderr.innerHTML = line.stderr; tbody.append(<tr> <td> <time datetime={line.tested}> {new Date(line.tested).toLocaleString()} </time> </td> <td>{holes[line.hole]}</td> <td>{langs[line.lang]}</td> <td>{`${line.golfer} (${line.golfer_id})`}</td> <td>{comma(Math.round(line.took / 1e6)) + 'ms'}</td> <td><span class={line.pass ? 'green' : 'red'}> {line.pass ? 'PASS' : 'FAIL'} </span></td> <td>{stderr}</td> </tr>); }; reader.read().then(function process({ done, value }) { if (done) { if (buffer) append(buffer); run.style.display = 'block'; stop.style.display = 'none'; return; } const lines = (buffer += decoder.decode(value)).split(/\n(?=.)/); buffer = lines.pop() ?? ''; lines.forEach(append); reader.read().then(process); }); }; ```
/content/code_sandbox/js/admin/solutions.tsx
xml
2016-10-02T12:09:24
2024-08-16T19:53:45
code-golf
code-golf/code-golf
1,116
622
```xml <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "path_to_url"> <!-- Name: ink dark colour scheme Author: Julien Zamor, troisyaourts - Dark scheme Author: Joseph Humfrey, inkle - Initial light scheme URL: path_to_url Adapted from 3024 (Day) by Jan T. Sott --> <plist version="1.0"> <dict> <key>author</key> <string>Joseph Humfrey, inkle </string> <key>name</key> <string>ink dark theme</string> <key>comment</key> <string>path_to_url <key>semanticClass</key> <string>theme.dark.ink</string> <key>colorSpaceName</key> <string>sRGB</string> <key>settings</key> <array> <dict> <key>settings</key> <dict> <key>background</key> <string>#282828</string> <key>caret</key> <string>#F8F8F0</string> <key>foreground</key> <string>#F8F8F2</string> <key>invisibles</key> <string>#49483E</string> <key>lineHighlight</key> <string>#49483E</string> <key>selection</key> <string>#49483E</string> </dict> </dict> <dict> <key>name</key> <string>Knot and stitch declarations</string> <key>scope</key> <string>meta.knot.declaration, meta.stitch.declaration</string> <key>settings</key> <dict> <key>fontStyle</key> <string>bold</string> <key>foreground</key> <string>#66D9EF</string> </dict> </dict> <dict> <key>name</key> <string>Weave punctuation - choices, gather bullets and brackets</string> <key>scope</key> <string>keyword.operator.weaveBullet, keyword.operator.weaveBracket</string> <key>settings</key> <dict> <key>foreground</key> <string>#F92672</string> </dict> </dict> <dict> <key>name</key> <string>Label for choice or gather</string> <key>scope</key> <string>meta.label, entity.name.label</string> <key>settings</key> <dict> <key>foreground</key> <string>#66D9EF</string> </dict> </dict> <dict> <key>name</key> <string>Divert</string> <key>scope</key> <string>meta.divert, keyword.operator.divert, variable.divertTarget</string> <key>settings</key> <dict> <key>foreground</key> <string>#66D9EF</string> </dict> </dict> <dict> <key>name</key> <string>General logic</string> <key>scope</key> <string>meta.logic, keyword.operator, meta.multilineLogic, meta.logicBegin, entity.inlineConditional</string> <key>settings</key> <dict> <key>foreground</key> <string>#A6E22E</string> </dict> </dict> <dict> <key>name</key> <string>Global</string> <key>scope</key> <string>meta.variable</string> <key>settings</key> <dict> <key>foreground</key> <string>#AE81FF</string> </dict> </dict> <dict> <key>name</key> <string>TODO</string> <key>scope</key> <string>comment.todo</string> <key>settings</key> <dict> <key>foreground</key> <string>#FD971F</string> </dict> </dict> <dict> <key>name</key> <string>TODO</string> <key>scope</key> <string>comment.todo.TODO</string> <key>settings</key> <dict> <key>background</key> <string>#FFD569</string> </dict> </dict> <dict> <key>name</key> <string>Comments</string> <key>scope</key> <string>comment, punctuation.definition.comment</string> <key>settings</key> <dict> <key>foreground</key> <string>#888</string> </dict> </dict> <dict> <key>name</key> <string>Operators</string> <key>scope</key> <string>keyword.done, keyword.end</string> <key>settings</key> <dict> <key>foreground</key> <string>#66D9EF</string> </dict> </dict> <dict> <key>name</key> <string>Bold-italic text</string> <key>scope</key> <string>string.boldItalic</string> <key>settings</key> <dict> <key>fontStyle</key> <string>bold, italic</string> <key>foreground</key> <string>#FFF</string> </dict> </dict> <dict> <key>name</key> <string>Bold text</string> <key>scope</key> <string>string.bold</string> <key>settings</key> <dict> <key>fontStyle</key> <string>bold</string> <key>foreground</key> <string>#FFF</string> </dict> </dict> <dict> <key>name</key> <string>Italic text</string> <key>scope</key> <string>string.italic</string> <key>settings</key> <dict> <key>fontStyle</key> <string>italic</string> </dict> </dict> <!-- Keep main content at the end as a "last resort" --> <dict> <key>name</key> <string>Main content</string> <key>scope</key> <string>string</string> <key>settings</key> <dict> <key>foreground</key> <string>#fff</string> </dict> </dict> </array> <key>uuid</key> <string>14875ac8-6a02-493d-9cfa-1701c764e24b</string> </dict> </plist> ```
/content/code_sandbox/Sublime3Syntax/ink-dark.tmTheme
xml
2016-01-23T15:38:01
2024-08-16T20:02:36
ink
inkle/ink
4,025
1,726
```xml <RelativeLayout xmlns:android="path_to_url" xmlns:tools="path_to_url" android:layout_width="170dp" android:layout_height="200dp" android:background="@drawable/background" tools:context=".MainActivity"> <ImageView android:id="@+id/mouse" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerInParent="true" android:src="@drawable/mouse" /> <RelativeLayout android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerInParent="true"> <ImageView android:id="@+id/cat" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_centerInParent="true" android:src="@drawable/cat" /> <ImageView android:id="@+id/eye_left" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="3.5dp" android:layout_marginTop="12.5dp" android:src="@drawable/eyes" /> <com.roger.catloadinglibrary.EyelidView android:id="@+id/eyelid_left" android:layout_width="24dp" android:layout_height="15dp" android:layout_marginLeft="3.5dp" android:layout_marginTop="12.5dp" android:src="@drawable/eyes" /> <ImageView android:id="@+id/eye_right" android:layout_width="wrap_content" android:layout_height="wrap_content" android:layout_marginLeft="28dp" android:layout_marginTop="12.5dp" android:src="@drawable/eyes" /> <com.roger.catloadinglibrary.EyelidView android:id="@+id/eyelid_right" android:layout_width="24dp" android:layout_height="15dp" android:layout_marginLeft="28dp" android:layout_marginTop="12.5dp" android:src="@drawable/eyes" /> </RelativeLayout> <com.roger.catloadinglibrary.GraduallyTextView android:id="@+id/graduallyTextView" android:layout_width="110dp" android:layout_height="wrap_content" android:layout_alignParentBottom="true" android:layout_centerHorizontal="true" android:layout_marginBottom="10dp" android:text="L O A D I N G ..." android:textColor="#ffffff" android:textSize="15sp" /> </RelativeLayout> ```
/content/code_sandbox/app/app/src/main/res/layout/catloading_main.xml
xml
2016-10-27T09:31:28
2024-08-16T19:00:35
nexmon
seemoo-lab/nexmon
2,381
575
```xml import { shallow, mount } from "enzyme" import * as React from "react" import { Sessions, Container } from "./../browser/src/Services/Sessions/Sessions" import TextInputView from "../browser/src/UI/components/LightweightText" const noop = () => ({}) jest.mock("./../browser/src/neovim/SharedNeovimInstance", () => ({ getInstance: () => ({ bindToMenu: () => ({ setItems: jest.fn(), onCursorMoved: { subscribe: jest.fn(), }, }), }), })) describe("<Sessions />", () => { const sessions = [ { name: "test", id: "test-1", file: "/sessions/test.vim", directory: "/sessions", updatedAt: null, workspace: "/workspace", }, { name: "testing", id: "testing-2", file: "/sessions/testing.vim", directory: "/sessions", updatedAt: null, workspace: "/workspace", }, ] it("should render without crashing", () => { const wrapper = shallow( <Sessions active cancelCreating={noop} createSession={noop} persistSession={noop} restoreSession={noop} updateSession={noop} getAllSessions={noop} updateSelection={noop} sessions={sessions} creating={false} selected={sessions[0]} populateSessions={noop} />, ) }) it("should render no children if showAll is false", () => { const wrapper = shallow( <Sessions active cancelCreating={noop} createSession={noop} persistSession={noop} restoreSession={noop} updateSession={noop} getAllSessions={noop} updateSelection={noop} sessions={sessions} creating={false} selected={sessions[0]} populateSessions={noop} />, ) wrapper.setState({ showAll: false }) const items = wrapper .dive() .find("ul") .children() expect(items.length).toBe(0) }) it("should render correct number of children if showAll is true", () => { const wrapper = mount( <Sessions active cancelCreating={noop} createSession={noop} persistSession={noop} restoreSession={noop} updateSession={noop} getAllSessions={noop} updateSelection={noop} sessions={sessions.slice(1)} // remove one session creating={false} selected={sessions[0]} populateSessions={noop} />, ) wrapper.setState({ showAll: true }) const items = wrapper.find("ul").children() expect(items.length).toBe(3) }) it("should render an input if creating is true", () => { const wrapper = mount( <Sessions active cancelCreating={noop} createSession={noop} persistSession={noop} restoreSession={noop} updateSession={noop} getAllSessions={noop} updateSelection={noop} sessions={sessions.slice(1)} // remove one session creating={true} selected={sessions[0]} populateSessions={noop} />, ) const hasInput = wrapper.find(TextInputView).length expect(hasInput).toBeTruthy() }) it("should render no input if creating is false", () => { const wrapper = mount( <Sessions active cancelCreating={noop} createSession={noop} persistSession={noop} restoreSession={noop} updateSession={noop} getAllSessions={noop} updateSelection={noop} sessions={sessions.slice(1)} creating={false} selected={null} populateSessions={noop} />, ) const hasInput = wrapper.find(TextInputView).length expect(hasInput).toBeFalsy() }) it("should empty message if there are no sessions", () => { const wrapper = mount( <Sessions active cancelCreating={noop} createSession={noop} persistSession={noop} restoreSession={noop} updateSession={noop} getAllSessions={noop} updateSelection={noop} sessions={[]} creating={true} selected={null} populateSessions={noop} />, ) expect(wrapper.find(Container).length).toBe(1) expect(wrapper.find(Container).text()).toBe("No Sessions Saved") }) }) ```
/content/code_sandbox/ui-tests/Sessions.test.tsx
xml
2016-11-16T14:42:55
2024-08-14T11:48:05
oni
onivim/oni
11,355
965
```xml import './no-unnecessary-split-diff-view.css'; import * as pageDetect from 'github-url-detection'; import features from '../feature-manager.js'; void features.addCssFeature(import.meta.url, [ pageDetect.hasFiles, ]); /* ## Test URLs ### PR files path_to_url ### PR files with annotations path_to_url ### Compare page path_to_url ### Single commit path_to_url */ ```
/content/code_sandbox/source/features/no-unnecessary-split-diff-view.tsx
xml
2016-02-15T16:45:02
2024-08-16T18:39:26
refined-github
refined-github/refined-github
24,013
89
```xml import { findForkedRemotesToPrune } from '../../src/lib/stores/helpers/find-forked-remotes-to-prune' import { Branch, BranchType } from '../../src/models/branch' import { CommitIdentity } from '../../src/models/commit-identity' import { GitHubRepository } from '../../src/models/github-repository' import { PullRequest } from '../../src/models/pull-request' import { IRemote } from '../../src/models/remote' import { gitHubRepoFixture } from '../helpers/github-repo-builder' function createSamplePullRequest( gitHubRepository: GitHubRepository, userName: string, baseBranchName: string ) { return new PullRequest( new Date(), 'desktop', 1, { ref: 'main', sha: 'deadbeef', gitHubRepository, }, { ref: baseBranchName, sha: 'deadbeef', gitHubRepository, }, userName, false, 'sample body' ) } function createSampleBranch(name: string, upstream: string | null) { const author = new CommitIdentity( 'someone', 'someone@somewhere.com', new Date() ) const branchTip = { sha: '300acef', author, } return new Branch(name, upstream, branchTip, BranchType.Local, '') } describe('findForkedRemotesToPrune', () => { const TestUserName = 'sergiou87' const OriginRemote = 'origin' const NonGitHubDesktopRemote = 'non-github-desktop-remote' const GitHubDesktopRemoteWithLocalBranch = 'github-desktop-niik' const GitHubDesktopRemoteWithPullRequest = `github-desktop-${TestUserName}` const remotes = [ { name: OriginRemote, url: 'path_to_url }, { name: NonGitHubDesktopRemote, url: 'path_to_url }, { name: GitHubDesktopRemoteWithLocalBranch, url: 'path_to_url }, { name: GitHubDesktopRemoteWithPullRequest, url: `path_to_url{TestUserName}/desktop.git`, }, ] function getNamesFromRemotes(remotes: readonly IRemote[]) { return remotes.map(r => r.name) } it('never prunes remotes not created by the app', () => { const remotesToPrune = findForkedRemotesToPrune(remotes, [], []) const names = getNamesFromRemotes(remotesToPrune) expect(names).not.toBeEmpty() expect(names).not.toContain(OriginRemote) expect(names).not.toContain(NonGitHubDesktopRemote) }) it('never prunes remotes with local branches', () => { const allBranches = [ createSampleBranch( 'app-store-refactor', `${GitHubDesktopRemoteWithLocalBranch}/app-store-refactor` ), ] const remotesToPrune = findForkedRemotesToPrune(remotes, [], allBranches) expect(getNamesFromRemotes(remotesToPrune)).not.toContain( GitHubDesktopRemoteWithLocalBranch ) }) it('never prunes remotes with pull requests', () => { const forkRepository = gitHubRepoFixture({ name: 'desktop', owner: TestUserName, }) const openPRs = [ createSamplePullRequest(forkRepository, TestUserName, 'my-cool-feature'), ] const remotesToPrune = findForkedRemotesToPrune(remotes, openPRs, []) expect(getNamesFromRemotes(remotesToPrune)).not.toContain( GitHubDesktopRemoteWithPullRequest ) }) it('prunes remotes without pull requests or local branches', () => { const remotesToPrune = findForkedRemotesToPrune(remotes, [], []) const remoteNames = getNamesFromRemotes(remotesToPrune) expect(remoteNames).toContain(GitHubDesktopRemoteWithPullRequest) expect(remoteNames).toContain(GitHubDesktopRemoteWithLocalBranch) }) }) ```
/content/code_sandbox/app/test/unit/find-forked-remotes-to-prune-test.ts
xml
2016-05-11T15:59:00
2024-08-16T17:00:41
desktop
desktop/desktop
19,544
912
```xml import EventEmitter from 'events'; import JitsiConference from '../../JitsiConference'; import { MediaType } from '../../service/RTC/MediaType'; import { VideoType } from '../../service/RTC/VideoType'; import TraceablePeerConnection from './TraceablePeerConnection'; export default class JitsiTrack extends EventEmitter { constructor( conference: JitsiConference, stream: unknown, track: unknown, streamInactiveHandler: unknown, trackMediaType: MediaType, videoType: VideoType ); // TODO: readonly conference: null | JitsiConference; disposed: boolean; getVideoType: () => VideoType; getType: () => MediaType; isAudioTrack: () => boolean; isWebRTCTrackMuted: () => boolean; isVideoTrack: () => boolean; isLocal: () => boolean; isLocalAudioTrack: () => boolean; getOriginalStream: () => MediaStream; getStreamId: () => string | null; getTrack: () => MediaStreamTrack; getTrackLabel: () => string; getTrackId: () => string | null; getUsageLabel: () => string; attach: ( container: HTMLElement ) => void; detach: ( container: HTMLElement ) => void; dispose: () => void; isScreenSharing: () => boolean; getId: () => string | null; isActive: () => boolean; setAudioLevel: ( audioLevel: number, tpc: TraceablePeerConnection ) => void; setAudioOutput: ( audioOutputDeviceId: '' | string ) => Promise<unknown>; // TODO: what will this promise contain? addEventListener: (type: string, listener: (event: any) => void) => void; } ```
/content/code_sandbox/types/hand-crafted/modules/RTC/JitsiTrack.d.ts
xml
2016-01-27T22:44:09
2024-08-16T02:51:56
lib-jitsi-meet
jitsi/lib-jitsi-meet
1,328
376
```xml <?xml version="1.0" encoding="UTF-8"?> <!-- * * * path_to_url * * Unless required by applicable law or agreed to in writing, software * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --> <project xmlns="path_to_url" xmlns:xsi="path_to_url" xsi:schemaLocation="path_to_url path_to_url"> <modelVersion>4.0.0</modelVersion> <groupId>com.google.training</groupId> <artifactId>appdev</artifactId> <version>0.0.1</version> <packaging>jar</packaging> <name>appdev</name> <description>Quiz Application</description> <parent> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-parent</artifactId> <version>2.5.6</version> <relativePath/> </parent> <properties> <project.build.sourceEncoding>UTF-8</project.build.sourceEncoding> <project.reporting.outputEncoding>UTF-8</project.reporting.outputEncoding> <java.version>1.8</java.version> <google.datastore.version>2.2.0</google.datastore.version> <google.pubsub.version>1.114.7</google.pubsub.version> <google.languageapi.version>2.1.3</google.languageapi.version> <google.spanner.version>6.15.2</google.spanner.version> <google.cloudstorage.version>2.2.0</google.cloudstorage.version> <google-api-pubsub.version>v1-rev452-1.25.0</google-api-pubsub.version> </properties> <dependencies> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-actuator</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-web</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-thymeleaf</artifactId> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-devtools</artifactId> <scope>runtime</scope> </dependency> <dependency> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-starter-test</artifactId> <scope>test</scope> <exclusions> <exclusion> <groupId>com.vaadin.external.google</groupId> <artifactId>android-json</artifactId> </exclusion> </exclusions> </dependency> <dependency> <groupId>com.google.cloud</groupId> <artifactId>google-cloud-datastore</artifactId> <version>${google.datastore.version}</version> <exclusions> <exclusion> <groupId>io.netty</groupId> <artifactId>netty-all</artifactId> </exclusion> </exclusions> </dependency> <dependency> <groupId>com.google.cloud</groupId> <artifactId>google-cloud-storage</artifactId> <version>${google.cloudstorage.version}</version> </dependency> <dependency> <groupId>com.google.cloud</groupId> <artifactId>google-cloud-pubsub</artifactId> <version>${google.pubsub.version}</version> <exclusions> <exclusion> <groupId>io.netty</groupId> <artifactId>netty-all</artifactId> </exclusion> </exclusions> </dependency> <dependency> <groupId>io.netty</groupId> <artifactId>netty-all</artifactId> <version>4.1.70.Final</version> </dependency> <dependency> <groupId>com.google.cloud</groupId> <artifactId>google-cloud-language</artifactId> <version>${google.languageapi.version}</version> </dependency> <dependency> <groupId>com.google.cloud</groupId> <artifactId>google-cloud-spanner</artifactId> <version>${google.spanner.version}</version> </dependency> <dependency> <groupId>com.google.apis</groupId> <artifactId>google-api-services-pubsub</artifactId> <version>${google-api-pubsub.version}</version> </dependency> </dependencies> <build> <plugins> <plugin> <groupId>org.springframework.boot</groupId> <artifactId>spring-boot-maven-plugin</artifactId> <version>2.5.6</version> </plugin> <plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-compiler-plugin</artifactId> <version>3.8.1</version> <configuration> <source>${java.version}</source> <target>${java.version}</target> </configuration> </plugin> <plugin> <groupId>org.codehaus.mojo</groupId> <artifactId>exec-maven-plugin</artifactId> <version>3.0.0</version> <executions> <execution> <id>worker</id> <goals> <goal>java</goal> </goals> <configuration> <mainClass>com.google.training.appdev.console.ConsoleApp</mainClass> </configuration> </execution> </executions> </plugin> </plugins> </build> </project> ```
/content/code_sandbox/courses/developingapps/v1.3/java/datastore/start/pom.xml
xml
2016-04-17T21:39:27
2024-08-16T17:22:27
training-data-analyst
GoogleCloudPlatform/training-data-analyst
7,726
1,293
```xml import {Torrent} from "../abstracttorrent"; import {TorrentActionList, TorrentClient, TorrentUpdates, ContextActionList, TorrentUploadOptions, TorrentUploadOptionsEnable} from "../torrentclient"; import {QBittorrentTorrent} from "./torrentq"; type CallbackFunc = (err: any, val: any) => void function defer<T>(fn: (f: CallbackFunc) => void): Promise<T> { return new Promise((resolve, reject) => { fn((err, val) => { if (err) { reject(err) } else { resolve(val) } }) }) } export interface QBittorrentUploadOptions { savepath?: string cookie?: string category?: string tags?: string skip_checking?: boolean paused?: boolean root_folder?: boolean rename?: string upLimit?: number dlLimit?: number autoTMM?: boolean sequentialDownload?: boolean firstLastPiecePrio?: boolean } type QBittorrentUploadFormData = Partial<Record<keyof QBittorrentUploadOptions, string | Uint8Array | Buffer>> const QBittorrent = require("@electorrent/node-qbittorrent"); export class QBittorrentClient extends TorrentClient<QBittorrentTorrent> { public name = "qBittorrent" public id = "qbittorrent" private qbittorrent: any connect(server): Promise<void> { let ca = server.getCertificate(); this.qbittorrent = new QBittorrent({ host: server.url(), port: server.port, path: server.cleanPath(), user: server.user, pass: server.password, ca: server.getCertificate(), }) return defer(done => { this.qbittorrent.login(done) }) }; torrents(fullupdate?: boolean): Promise<TorrentUpdates> { let p = Promise.resolve() if (fullupdate) { p = p.then(() => defer(done => this.qbittorrent.reset(done))) } return p .then(() => { return defer(done => this.qbittorrent.syncMaindata(done)); }) .then((data) => { return this.processData(data); }); }; processData(data: Record<string, any>) { var torrents = { labels: [], all: [], changed: [], deleted: [], }; if (Array.isArray(data.categories) || Array.isArray(data.labels)) { torrents.labels = data.categories || data.labels; } else if (typeof data.categories === "object") { torrents.labels = Object.values(data.categories).map((c: any) => c.name); } if (data.full_update) { torrents.all = this.buildAll(data.torrents); } else { torrents.changed = this.buildAll(data.torrents); } torrents.deleted = data.torrents_removed || []; return torrents; } buildAll(torrents: Record<string, any>) { if (!torrents) return []; var torrentArray = []; Object.keys(torrents).map(function (hash) { var torrent = new QBittorrentTorrent(hash, torrents[hash]); torrentArray.push(torrent); }); return torrentArray; } defaultPath() { return "/"; }; /** * Transforms generic upload options to QBittorrent spefific ones. Options are returned in * a form data compatible format accepted by the QBittorrent API. The returned object can * be used directly in a HTTP post request */ private getHttpUploadOptions(options: TorrentUploadOptions): QBittorrentUploadFormData { let qbittorrentOptions: Required<QBittorrentUploadOptions> = { savepath: options.saveLocation, cookie: undefined, category: options.category, tags: undefined, skip_checking: options.skipCheck, paused: !options.startTorrent, root_folder: undefined, rename: options.renameTorrent, upLimit: options.uploadSpeedLimit, dlLimit: options.downloadSpeedLimit, autoTMM: undefined, sequentialDownload: options.sequentialDownload, firstLastPiecePrio: options.firstAndLastPiecePrio, } let formData: QBittorrentUploadFormData = {} // remove values which are undefined and transform into http form style for (let k in qbittorrentOptions) { if (qbittorrentOptions[k] !== undefined && qbittorrentOptions[k] !== null) { formData[k] = qbittorrentOptions[k].toString() } } return formData } uploadTorrent(buffer: Uint8Array, filename: string, options: TorrentUploadOptions): Promise<void> { let data = Buffer.from(buffer); let httpFormOptions = undefined if (options !== undefined) { httpFormOptions = this.getHttpUploadOptions(options) } return defer(done => this.qbittorrent.addTorrentFileContent(data, filename, httpFormOptions, done)); }; addTorrentUrl(magnet: string, options?: TorrentUploadOptions): Promise<void> { let httpFormOptions = undefined if (options !== undefined) { httpFormOptions = this.getHttpUploadOptions(options) } return defer(done => this.qbittorrent.addTorrentURL(magnet, httpFormOptions, done)); }; public uploadOptionsEnable: TorrentUploadOptionsEnable = { saveLocation: true, renameTorrent: true, category: true, startTorrent: true, skipCheck: true, sequentialDownload: true, firstAndLastPiecePrio: true, downloadSpeedLimit: true, uploadSpeedLimit: true, } enableTrackerFilter = false; extraColumns = []; /* * Actions */ resume(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.resume(torrents.map((t) => t.hash), done)); }; resumeAll(): Promise<void> { return defer(done => this.qbittorrent.resumeAll(done)); }; pause(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.pause(torrents.map((t) => t.hash), done)); }; pauseAll(): Promise<void> { return defer(done => this.qbittorrent.pauseAll(done)); }; recheck(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.recheck(torrents.map((t) => t.hash), done)); }; increasePrio(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.increasePrio(torrents.map((t) => t.hash), done)); }; decreasePrio(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.decreasePrio(torrents.map((t) => t.hash), done)); }; topPrio(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.topPrio(torrents.map((t) => t.hash), done)); }; bottomPrio(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.bottomPrio(torrents.map((t) => t.hash), done)); }; toggleSequentialDownload(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.toggleSequentialDownload(torrents.map((t) => t.hash), done)); }; delete(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.delete(torrents.map((t) => t.hash), done)); }; deleteAndRemove(torrents: Torrent[]): Promise<void> { return defer(done => this.qbittorrent.deleteAndRemove(torrents.map((t) => t.hash), done)); }; setCategory(torrents: Torrent[], category: string, create?: boolean): Promise<void> { let promise = Promise.resolve() if (create === true) { promise = promise.then(() => defer(done => this.qbittorrent.createCategory(category, "", done))); } let hashes = torrents.map((t) => t.hash); return promise.then(() => defer(done => this.qbittorrent.setCategory(hashes, category, done))); }; /** * Delete function to satisfy interface implementation * @param torrents torrent to delete * @returns promise that torrents were deleted */ deleteTorrents(torrents: QBittorrentTorrent[]): Promise<void> { return this.delete(torrents) } actionHeader: TorrentActionList<QBittorrentTorrent> = [ { label: "Start", type: "button", color: "green", click: this.resume, icon: "play", role: "resume", }, { label: "Pause", type: "button", color: "red", click: this.pause, icon: "pause", role: "stop", }, { label: "More", type: "dropdown", color: "blue", icon: "plus", actions: [ { label: "Pause All", click: this.pauseAll, }, { label: "Resume All", click: this.resumeAll, }, ], }, { label: "Labels", click: this.setCategory, type: "labels", }, ]; /** * Represents the actions available in the context menu. Can be customized to your liking or * to better accommodate your bittorrent client. Every action must have a click function implemented. * Each element has an: * label [string]: The name of the action * click [function]: The function to be executed when clicked * icon [string]: The icon of the action. See here: path_to_url * check [function]: Displays a checkbox instead of an icon. The function is a predicate which * has to hold for all selected torrents, for the checkbox to be checked. */ contextMenu: ContextActionList<QBittorrentTorrent> = [ { label: "Recheck", click: this.recheck, icon: "checkmark", }, { label: "Move Up Queue", click: this.increasePrio, icon: "arrow up", }, { label: "Move Queue Down", click: this.decreasePrio, icon: "arrow down", }, { label: "Queue Top", click: this.topPrio, icon: "chevron circle up", }, { label: "Queue Bottom", click: this.bottomPrio, icon: "chevron circle down", }, { label: "Sequential Download", click: this.toggleSequentialDownload, check: function (torrent: QBittorrentTorrent) { return torrent.sequentialDownload; }, }, { label: "Remove", click: this.delete, icon: "remove", }, { label: "Remove And Delete", click: this.deleteAndRemove, icon: "trash", role: "delete", }, ]; } ```
/content/code_sandbox/src/scripts/bittorrent/qbittorrent/qbittorrentservice.ts
xml
2016-06-18T15:04:41
2024-08-16T07:12:27
Electorrent
tympanix/Electorrent
1,016
2,437
```xml import { isFunction } from 'underscore'; import AssetView from './AssetView'; import AssetImage from '../model/AssetImage'; import html from '../../utils/html'; export default class AssetImageView extends AssetView<AssetImage> { getPreview() { const { pfx, ppfx, model } = this; const src = model.get('src'); return html` <div class="${pfx}preview" style="background-image: url('${src}');"></div> <div class="${pfx}preview-bg ${ppfx}checker-bg"></div> `; } getInfo() { const { pfx, model } = this; let name = model.get('name'); let width = model.get('width'); let height = model.get('height'); let unit = model.get('unitDim'); let dim = width && height ? `${width}x${height}${unit}` : ''; name = name || model.getFilename(); return html` <div class="${pfx}name">${name}</div> <div class="${pfx}dimensions">${dim}</div> `; } // @ts-ignore init(o) { const pfx = this.pfx; this.className += ` ${pfx}asset-image`; } /** * Triggered when the asset is clicked * @private * */ onClick() { const { model, pfx } = this; const { select } = this.__getBhv(); // @ts-ignore const { onClick } = this.config; const coll = this.collection; coll.trigger('deselectAll'); this.$el.addClass(pfx + 'highlight'); if (isFunction(select)) { select(model, false); } else if (isFunction(onClick)) { onClick(model); } else { // @ts-ignore this.updateTarget(coll.target); } } /** * Triggered when the asset is double clicked * @private * */ onDblClick() { const { em, model } = this; const { select } = this.__getBhv(); // @ts-ignore const { onDblClick } = this.config; // @ts-ignore const { target, onSelect } = this.collection; if (isFunction(select)) { select(model, true); } else if (isFunction(onDblClick)) { onDblClick(model); } else { this.updateTarget(target); em?.Modal.close(); } isFunction(onSelect) && onSelect(model); } /** * Remove asset from collection * @private * */ onRemove(e: Event) { e.stopImmediatePropagation(); this.model.collection.remove(this.model); } } AssetImageView.prototype.events = { // @ts-ignore 'click [data-toggle=asset-remove]': 'onRemove', click: 'onClick', dblclick: 'onDblClick', }; ```
/content/code_sandbox/src/asset_manager/view/AssetImageView.ts
xml
2016-01-22T00:23:19
2024-08-16T11:20:59
grapesjs
GrapesJS/grapesjs
21,687
644
```xml /* * one or more contributor license agreements. See the NOTICE file distributed * with this work for additional information regarding copyright ownership. */ import {Route} from '@playwright/test'; import { FlowNodeInstanceDto, FlowNodeInstancesDto, } from 'modules/api/fetchFlowNodeInstances'; import {MetaDataDto} from 'modules/api/processInstances/fetchFlowNodeMetaData'; import {ProcessInstanceDetailStatisticsDto} from 'modules/api/processInstances/fetchProcessInstanceDetailStatistics'; import {ProcessInstanceIncidentsDto} from 'modules/api/processInstances/fetchProcessInstanceIncidents'; import {SequenceFlowsDto} from 'modules/api/processInstances/sequenceFlows'; type InstanceMock = { xml: string; detail: ProcessInstanceEntity; flowNodeInstances: FlowNodeInstancesDto<FlowNodeInstanceDto>; statistics: ProcessInstanceDetailStatisticsDto[]; sequenceFlows: SequenceFlowsDto; variables: VariableEntity[]; incidents?: ProcessInstanceIncidentsDto; metaData?: MetaDataDto; }; function mockResponses({ processInstanceDetail, flowNodeInstances, statistics, sequenceFlows, variables, xml, incidents, metaData, }: { processInstanceDetail?: ProcessInstanceEntity; flowNodeInstances?: FlowNodeInstancesDto<FlowNodeInstanceDto>; statistics?: ProcessInstanceDetailStatisticsDto[]; sequenceFlows?: SequenceFlowsDto; variables?: VariableEntity[]; xml?: string; incidents?: ProcessInstanceIncidentsDto; metaData?: MetaDataDto; }) { return (route: Route) => { if (route.request().url().includes('/api/authentications/user')) { return route.fulfill({ status: 200, body: JSON.stringify({ userId: 'demo', displayName: 'demo', canLogout: true, permissions: ['read', 'write'], roles: null, salesPlanType: null, c8Links: {}, username: 'demo', }), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('/api/flow-node-instances')) { return route.fulfill({ status: flowNodeInstances === undefined ? 400 : 200, body: JSON.stringify(flowNodeInstances), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('statistics')) { return route.fulfill({ status: statistics === undefined ? 400 : 200, body: JSON.stringify(statistics), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('sequence-flows')) { return route.fulfill({ status: sequenceFlows === undefined ? 400 : 200, body: JSON.stringify(sequenceFlows), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('variables')) { return route.fulfill({ status: variables === undefined ? 400 : 200, body: JSON.stringify(variables), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('xml')) { return route.fulfill({ status: xml === undefined ? 400 : 200, body: JSON.stringify(xml), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('incidents')) { return route.fulfill({ status: incidents === undefined ? 400 : 200, body: JSON.stringify(incidents), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('flow-node-metadata')) { return route.fulfill({ status: metaData === undefined ? 400 : 200, body: JSON.stringify(metaData), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('/api/process-instances/')) { return route.fulfill({ status: processInstanceDetail === undefined ? 400 : 200, body: JSON.stringify(processInstanceDetail), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('/modify')) { return route.fulfill({ status: 200, body: JSON.stringify({ id: '5f663d9d-1b0e-4243-90d9-43370f4b707c', name: null, type: 'MODIFY_PROCESS_INSTANCE', startDate: '2023-10-04T11:35:28.241+0200', endDate: null, username: 'demo', instancesCount: 1, operationsTotalCount: 1, operationsFinishedCount: 0, }), headers: { 'content-type': 'application/json', }, }); } if (route.request().url().includes('/operation')) { return route.fulfill({ status: 200, body: JSON.stringify({ id: '4dccc4e0-7658-49d9-9361-cf9e73ee2052', name: null, type: 'DELETE_PROCESS_INSTANCE', startDate: '2023-10-04T14:25:23.613+0200', endDate: null, username: 'demo', instancesCount: 1, operationsTotalCount: 1, operationsFinishedCount: 0, }), headers: { 'content-type': 'application/json', }, }); } route.continue(); }; } export type {InstanceMock}; export {mockResponses}; export {completedInstance} from './completedInstance.mocks'; export {completedOrderProcessInstance} from './completedOrderProcessInstance.mocks'; export {eventBasedGatewayProcessInstance} from './eventBasedGatewayProcessInstance.mocks'; export {instanceWithIncident} from './instanceWithIncident.mocks'; export {orderProcessInstance} from './orderProcessInstance.mocks'; export {runningInstance} from './runningInstance.mocks'; export {runningOrderProcessInstance} from './runningOrderProcessInstance.mocks'; export {compensationProcessInstance} from './compensationProcessInstance.mocks'; ```
/content/code_sandbox/operate/client/e2e-playwright/mocks/processInstance/index.ts
xml
2016-03-20T03:38:04
2024-08-16T19:59:58
camunda
camunda/camunda
3,172
1,375
```xml import * as React from 'react'; import { ControlsAreaPage, IControlsPageProps } from '../ControlsAreaPage'; import { VerticalBarChartPageProps } from './VerticalBarChartPage.doc'; export const VerticalBarChartPage: React.FunctionComponent<IControlsPageProps> = props => { const { platform } = props; return <ControlsAreaPage {...props} {...VerticalBarChartPageProps[platform!]} />; }; ```
/content/code_sandbox/apps/public-docsite/src/pages/Controls/VerticalBarChartPage/VerticalBarChartPage.tsx
xml
2016-06-06T15:03:44
2024-08-16T18:49:29
fluentui
microsoft/fluentui
18,221
90
```xml <!-- ~ contributor license agreements. See the NOTICE file distributed with ~ this work for additional information regarding copyright ownership. ~ ~ path_to_url ~ ~ Unless required by applicable law or agreed to in writing, software ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --> <dataset> <metadata> <column name="group_name"/> <column name="in_redistribution"/> <column name="group_members"/> <column name="group_buckets"/> <column name="is_installation"/> <column name="group_acl"/> <column name="group_kind"/> <column name="group_parent"/> </metadata> </dataset> ```
/content/code_sandbox/test/e2e/sql/src/test/resources/cases/dql/dataset/empty_storage_units/opengauss/select_opengauss_pg_catalog_pgxc_group.xml
xml
2016-01-18T12:49:26
2024-08-16T15:48:11
shardingsphere
apache/shardingsphere
19,707
152
```xml import {ASTNode} from '../../ast'; import {TemplateParser} from '../template-parser'; import './tokenizer-case-sensitivity-patch'; import './drop-named-entities-patch'; var Parser = require('../../../../vendor/parse5/lib/parser'); var Serializer = require('../../../../vendor/parse5/lib/serializer'); export class Parse5TemplateParser extends TemplateParser { parse(template: string): ASTNode { var parser = new Parser(); return parser.parse(template); } serialize(node: ASTNode): string { var serializer = new Serializer(node); return serializer.serialize(); } } ```
/content/code_sandbox/app-shell/src/experimental/shell-parser/template-parser/parse5/parse5-template-parser.ts
xml
2016-01-25T17:36:44
2024-08-15T10:53:22
mobile-toolkit
angular/mobile-toolkit
1,336
125
```xml import * as React from 'react'; import { Datepicker, Button } from '@fluentui/react-northstar'; const defaultSelectedDate = new Date(2020, 6, 23, 0, 0, 0, 0); const getNextDay = (date: Date) => { date.setDate(date.getDate() + 1); return new Date(date.getTime()); }; const DatepickerExample = () => { const [selectedDate, setSelectedDate] = React.useState(undefined); return ( <> <Datepicker today={new Date(2020, 6, 23, 0, 0, 0, 0)} defaultSelectedDate={defaultSelectedDate} selectedDate={selectedDate} /> <Button className="select-next-day" content="Select the next day" onClick={() => { setSelectedDate(selectedDate => { if (!selectedDate) { return getNextDay(defaultSelectedDate); } return getNextDay(selectedDate); }); }} /> </> ); }; export default DatepickerExample; ```
/content/code_sandbox/packages/fluentui/e2e/tests/datepickerWithControlledSelectedDate-example.tsx
xml
2016-06-06T15:03:44
2024-08-16T18:49:29
fluentui
microsoft/fluentui
18,221
233
```xml import * as assert from 'assert'; import * as sinon from 'sinon'; import { anyString, instance, mock, when } from 'ts-mockito'; import { FileSystem } from '../../client/common/platform/fileSystem'; import { IFileSystem } from '../../client/common/platform/types'; import * as Telemetry from '../../client/telemetry'; import { setExtensionInstallTelemetryProperties } from '../../client/telemetry/extensionInstallTelemetry'; suite('Extension Install Telemetry', () => { let fs: IFileSystem; let telemetryPropertyStub: sinon.SinonStub; setup(() => { fs = mock(FileSystem); telemetryPropertyStub = sinon.stub(Telemetry, 'setSharedProperty'); }); teardown(() => { telemetryPropertyStub.restore(); }); test('PythonCodingPack exists', async () => { when(fs.fileExists(anyString())).thenResolve(true); await setExtensionInstallTelemetryProperties(instance(fs)); assert.ok(telemetryPropertyStub.calledOnceWithExactly('installSource', 'pythonCodingPack')); }); test('PythonCodingPack does not exists', async () => { when(fs.fileExists(anyString())).thenResolve(false); await setExtensionInstallTelemetryProperties(instance(fs)); assert.ok(telemetryPropertyStub.calledOnceWithExactly('installSource', 'marketPlace')); }); }); ```
/content/code_sandbox/src/test/telemetry/extensionInstallTelemetry.unit.test.ts
xml
2016-01-19T10:50:01
2024-08-12T21:05:24
pythonVSCode
DonJayamanne/pythonVSCode
2,078
280
```xml // @ts-ignore export * from './content'; ```
/content/code_sandbox/src/renderer/components/sidebar/components/index.tsx
xml
2016-05-14T02:18:49
2024-08-16T02:46:28
ElectroCRUD
garrylachman/ElectroCRUD
1,538
12
```xml /* * Squidex Headless CMS * * @license */ import { ContentDto, getContentValue, LanguageDto, LocalizerService, TagConverter, TagValue } from '@app/shared/internal'; export class ReferencesTagsConverter implements TagConverter { public tags: ReadonlyArray<TagValue> = []; constructor(language: LanguageDto, contents: ReadonlyArray<ContentDto>, private readonly localizer: LocalizerService, ) { this.tags = this.createTags(language, contents); } public convertInput(input: string) { const result = this.tags.find(x => x.name === input); return result || null; } public convertValue(value: any) { const result = this.tags.find(x => x.id === value); return result || null; } private createTags(language: LanguageDto, contents: ReadonlyArray<ContentDto>): ReadonlyArray<TagValue> { if (contents.length === 0) { return []; } const values = contents.map(content => { const name = content.referenceFields .map(f => getContentValue(content, language, f, false)) .map(v => v.formatted) .defined() .join(', ') || this.localizer.getOrKey('common.noValue'); return new TagValue(content.id, name, content.id); }); return values; } } ```
/content/code_sandbox/frontend/src/app/features/content/shared/references/references-tag-converter.ts
xml
2016-08-29T05:53:40
2024-08-16T17:39:38
squidex
Squidex/squidex
2,222
290
```xml export * from './FlightTrackerList'; export * from './FlightTrackerListItem'; export * from './FlightTrackerListItemAttribute'; export * from './FlightTrackerNoData'; export * from './RenderAttribute'; export * from './useFlightTrackerStyles'; ```
/content/code_sandbox/samples/react-flighttracker/src/components/FlightTrackerList/index.ts
xml
2016-08-30T17:21:43
2024-08-16T18:41:32
sp-dev-fx-webparts
pnp/sp-dev-fx-webparts
2,027
51
```xml import { Directive, HostBinding, HostListener, Input, OnChanges, Optional } from "@angular/core"; import { CipherView } from "@bitwarden/common/vault/models/view/cipher.view"; import { MenuItemDirective } from "@bitwarden/components"; import { CopyAction, CopyCipherFieldService } from "@bitwarden/vault"; /** * Directive to copy a specific field from a cipher on click. Uses the `CopyCipherFieldService` to * handle the copying of the field and any necessary password re-prompting or totp generation. * * Automatically disables the host element if the field to copy is not available or null. * * If the host element is a menu item, it will be hidden when disabled. * * @example * ```html * <button appCopyField="username" [cipher]="cipher">Copy Username</button> * ``` */ @Directive({ standalone: true, selector: "[appCopyField]", }) export class CopyCipherFieldDirective implements OnChanges { @Input({ alias: "appCopyField", required: true, }) action: Exclude<CopyAction, "hiddenField">; @Input({ required: true }) cipher: CipherView; constructor( private copyCipherFieldService: CopyCipherFieldService, @Optional() private menuItemDirective?: MenuItemDirective, ) {} @HostBinding("attr.disabled") protected disabled: boolean | null = null; /** * Hide the element if it is disabled and is a menu item. * @private */ @HostBinding("class.tw-hidden") private get hidden() { return this.disabled && this.menuItemDirective; } @HostListener("click") async copy() { const value = this.getValueToCopy(); await this.copyCipherFieldService.copy(value, this.action, this.cipher); } async ngOnChanges() { await this.updateDisabledState(); } private async updateDisabledState() { this.disabled = !this.cipher || !this.getValueToCopy() || (this.action === "totp" && !(await this.copyCipherFieldService.totpAllowed(this.cipher))) ? true : null; // If the directive is used on a menu item, update the menu item to prevent keyboard navigation if (this.menuItemDirective) { this.menuItemDirective.disabled = this.disabled; } } private getValueToCopy() { switch (this.action) { case "username": return this.cipher.login?.username || this.cipher.identity?.username; case "password": return this.cipher.login?.password; case "totp": return this.cipher.login?.totp; case "cardNumber": return this.cipher.card?.number; case "securityCode": return this.cipher.card?.code; case "email": return this.cipher.identity?.email; case "phone": return this.cipher.identity?.phone; case "address": return this.cipher.identity?.fullAddressForCopy; case "secureNote": return this.cipher.notes; default: return null; } } } ```
/content/code_sandbox/libs/vault/src/components/copy-cipher-field.directive.ts
xml
2016-03-09T23:14:01
2024-08-16T15:07:51
clients
bitwarden/clients
8,877
675
```xml <?xml version="1.0" encoding="utf-8"?> <manifest xmlns:android="path_to_url" xmlns:tools="path_to_url" android:installLocation="auto"> <uses-permission android:name="android.permission.INTERNET" /> <uses-permission android:name="android.permission.ACCESS_NETWORK_STATE" /> <uses-permission android:name="android.permission.WAKE_LOCK" tools:node="replace" /> <uses-permission android:name="android.permission.RECEIVE_BOOT_COMPLETED" /> <uses-permission android:name="android.permission.QUICKBOOT_POWERON" /> <uses-permission android:name="android.permission.ACCESS_WIFI_STATE" /> <uses-permission android:name="android.permission.CHANGE_WIFI_STATE" /> <uses-permission android:name="android.permission.VIBRATE" /> <uses-permission android:name="com.android.launcher.permission.INSTALL_SHORTCUT" /> <uses-permission android:name="android.permission.FOREGROUND_SERVICE" /> <uses-permission android:name="android.permission.FOREGROUND_SERVICE_DATA_SYNC" /> <uses-permission android:name="android.permission.READ_EXTERNAL_STORAGE" /> <uses-permission android:name="android.permission.WRITE_EXTERNAL_STORAGE" tools:ignore="ScopedStorage" /> <uses-permission android:name="android.permission.MANAGE_EXTERNAL_STORAGE" tools:ignore="ScopedStorage" /> <uses-permission android:name="android.permission.SCHEDULE_EXACT_ALARM" /> <uses-permission android:name="android.permission.POST_NOTIFICATIONS" /> <uses-feature android:name="android.hardware.touchscreen" android:required="false" /> <uses-feature android:name="android.software.leanback" android:required="false" /> <uses-feature android:name="android.hardware.wifi" android:required="false" /> <application android:name="MainApplication" android:icon="@mipmap/ic_launcher" android:banner="@drawable/ic_banner" android:label="@string/app_name" android:theme="@style/AppTheme" android:supportsRtl="true" android:allowBackup="true" android:fullBackupContent="true" android:usesCleartextTraffic="true" android:requestLegacyExternalStorage="true"> <activity android:name=".ui.main.MainActivity" android:theme="@style/AppTheme.Launcher" android:exported="true"> <meta-data android:name="android.app.shortcuts" android:resource="@xml/shortcuts" /> <meta-data android:name="android.app.searchable" android:resource="@xml/searchable"/> <intent-filter> <action android:name="android.intent.action.MAIN" /> <category android:name="android.intent.category.LAUNCHER" /> <category android:name="android.intent.category.LEANBACK_LAUNCHER" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.SEARCH" /> </intent-filter> </activity> <activity android:exported="true" android:name=".ui.addtorrent.AddTorrentActivity"> <intent-filter> <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:mimeType="application/x-bittorrent" android:scheme="file" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:pathPattern=".*\\.torrent" android:scheme="file" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:mimeType="application/x-bittorrent" android:scheme="content" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:pathPattern=".*\\.torrent" android:scheme="content" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:pathPattern=".*\\.torrent" android:scheme="http" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:pathPattern=".*\\.torrent" android:scheme="https" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:mimeType="*/*" android:pathPattern=".*\\.torrent" android:scheme="http" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:mimeType="*/*" android:pathPattern=".*\\.torrent" android:scheme="https" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:mimeType="application/x-bittorrent" android:scheme="http" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:host="*" android:mimeType="application/x-bittorrent" android:scheme="https" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:scheme="magnet" /> </intent-filter> </activity> <activity android:name=".ui.filemanager.FileManagerDialog" /> <activity android:name=".ui.detailtorrent.DetailTorrentActivity" /> <activity android:name=".ui.SendTextToClipboard" android:label="@string/send_text_to_clipboard" android:icon="@drawable/ic_content_copy_grey600_48dp" android:theme="@android:style/Theme.NoDisplay" android:exported="true"> <intent-filter> <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.ALTERNATIVE" /> <data android:name="android.content.Intent.FLAG_ACTIVITY_NO_ANIMATION" /> <data android:mimeType="text/*" /> </intent-filter> </activity> <activity android:name=".ui.settings.SettingsActivity" android:label="@string/settings" android:exported="true"> <intent-filter> <action android:name="android.intent.action.APPLICATION_PREFERENCES" /> <category android:name="android.intent.category.DEFAULT" /> </intent-filter> </activity> <activity android:name=".ui.settings.PreferenceActivity" /> <activity android:name=".ui.errorreport.ErrorReportActivity" android:theme="@style/AppTheme.Translucent" android:process=":acra" android:excludeFromRecents="true" android:finishOnTaskLaunch="true" android:launchMode="singleInstance" /> <activity android:name=".ui.feeds.FeedActivity" /> <activity android:name=".ui.feeditems.FeedItemsActivity" /> <activity android:name=".ui.addfeed.AddFeedActivity" android:exported="true" android:theme="@style/AppTheme.Translucent"> <intent-filter> <action android:name="android.intent.action.SEND" /> <category android:name="android.intent.category.DEFAULT" /> <data android:name="android.content.Intent.FLAG_ACTIVITY_NO_ANIMATION" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:name="android.content.Intent.FLAG_ACTIVITY_NO_ANIMATION" /> <data android:scheme="http" android:host="*" android:mimeType="*/*" /> <data android:pathPattern=".*\\.xml" /> <data android:pathPattern=".*\\.rss" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:name="android.content.Intent.FLAG_ACTIVITY_NO_ANIMATION" /> <data android:scheme="http" android:host="*" /> <data android:mimeType="text/xml" /> <data android:mimeType="application/rss+xml" /> <data android:mimeType="application/atom+xml" /> <data android:mimeType="application/xml" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:name="android.content.Intent.FLAG_ACTIVITY_NO_ANIMATION" /> <data android:scheme="https" android:host="*" android:mimeType="*/*" /> <data android:pathPattern=".*\\.xml" /> <data android:pathPattern=".*\\.rss" /> </intent-filter> <intent-filter> <action android:name="android.intent.action.VIEW" /> <category android:name="android.intent.category.DEFAULT" /> <category android:name="android.intent.category.BROWSABLE" /> <data android:name="android.content.Intent.FLAG_ACTIVITY_NO_ANIMATION" /> <data android:scheme="https" android:host="*" /> <data android:mimeType="text/xml" /> <data android:mimeType="application/rss+xml" /> <data android:mimeType="application/atom+xml" /> <data android:mimeType="application/xml" /> </intent-filter> </activity> <activity android:name=".ui.createtorrent.CreateTorrentActivity" android:theme="@style/AppTheme.Translucent" /> <activity android:name=".ui.addlink.AddLinkActivity" android:theme="@style/AppTheme.Translucent" /> <activity android:name=".ui.log.LogActivity" /> <activity android:name=".ui.log.LogSettingsActivity" /> <activity android:name=".ui.addtag.AddTagActivity" android:theme="@style/AppTheme.Translucent" /> <activity android:name=".ui.tag.SelectTagActivity" android:theme="@style/AppTheme.Translucent" /> <service android:name=".service.TorrentService" android:foregroundServiceType="dataSync" /> <receiver android:name=".receiver.NotificationReceiver" android:exported="false"> <intent-filter> <action android:name="org.proninyaroslav.libretorrent.receivers.NotificationReceiver.NOTIFY_ACTION_SHUTDOWN_APP" /> <action android:name="org.proninyaroslav.libretorrent.receivers.NotificationReceiver.NOTIFY_ACTION_ADD_TORRENT" /> </intent-filter> </receiver> <receiver android:name=".receiver.BootReceiver" android:exported="true"> <intent-filter> <action android:name="android.intent.action.BOOT_COMPLETED" /> <action android:name="android.intent.action.QUICKBOOT_POWERON" /> <action android:name="com.htc.intent.action.QUICKBOOT_POWERON" /> <action android:name="android.app.action.SCHEDULE_EXACT_ALARM_PERMISSION_STATE_CHANGED" /> </intent-filter> </receiver> <receiver android:name=".receiver.SchedulerReceiver" /> <provider android:name="androidx.core.content.FileProvider" android:authorities="${applicationId}.provider" android:exported="false" android:grantUriPermissions="true"> <meta-data android:name="android.support.FILE_PROVIDER_PATHS" android:resource="@xml/provider_paths"/> </provider> </application> </manifest> ```
/content/code_sandbox/app/src/main/AndroidManifest.xml
xml
2016-10-18T15:38:44
2024-08-16T19:19:31
libretorrent
proninyaroslav/libretorrent
1,973
2,845
```xml <?xml version="1.0" encoding="UTF-8"?> <LittleNavmap xmlns:xsi="path_to_url" xsi:noNamespaceSchemaLocation="path_to_url"> <!-- =========================================================================================== Units: MaximumRangeKm is the zoom distance in kilometers. Sizes like "AirportSymbolSize" are screen pixel. Scales like "AirportFontScale" are values that are multiplied with the stock/default object or font size. Booleans values like "AirportIdent" are yes/no or true/false. You can put a copy of this file into the Little Navmap settings folder ("C:/Users/YOURUSERNAME/AppData/Roaming/ABarthel/" on Windows) to override the default settings. Little Navmap will watch the file, reload it and redraw the map when it is changed. Using wrong settings in this file can crash or freeze the program. ================================================================================================ --> <MapLayerSettings> <Layers> <!-- =========================================================================================== This is the first default layer which defines the base for all other layers. All features in the default layer are enabled and derived layers disable these features step by step. ================================================================================================ --> <Layer Base="true"> <!-- AI aircraft and ship ================= --> <AiAircraftGround>true</AiAircraftGround> <AiAircraftGroundText>true</AiAircraftGroundText> <AiAircraftLarge>true</AiAircraftLarge> <AiAircraftSize>32</AiAircraftSize> <AiAircraftSmall>true</AiAircraftSmall> <AiAircraftText>true</AiAircraftText> <AiAircraftTextDetail>true</AiAircraftTextDetail> <AiAircraftTextDetail2>true</AiAircraftTextDetail2> <AiAircraftTextDetail3>true</AiAircraftTextDetail3> <AiShipLarge>true</AiShipLarge> <AiShipSmall>true</AiShipSmall> <!-- Airport ================= --> <Airport>true</Airport> <AirportDiagram>true</AirportDiagram> <AirportDiagramDetail>true</AirportDiagramDetail> <AirportDiagramDetail2>true</AirportDiagramDetail2> <AirportDiagramDetail3>true</AirportDiagramDetail3> <AirportDiagramRunway>true</AirportDiagramRunway> <AirportFontScale>1</AirportFontScale> <AirportIdent>true</AirportIdent> <AirportInfo>true</AirportInfo> <AirportMinor>true</AirportMinor> <AirportMinorFontScale>1</AirportMinorFontScale> <AirportMinorIdent>true</AirportMinorIdent> <AirportMinorInfo>true</AirportMinorInfo> <AirportMinorName>true</AirportMinorName> <AirportMinorSymbolSize>3</AirportMinorSymbolSize> <AirportMsa>true</AirportMsa> <AirportMsaDetails>true</AirportMsaDetails> <AirportMsaSymbolScale>6</AirportMsaSymbolScale> <AirportName>true</AirportName> <AirportNoRating>true</AirportNoRating> <AirportOverviewRunway>true</AirportOverviewRunway> <AirportRouteInfo>true</AirportRouteInfo> <AirportSymbolSize>3</AirportSymbolSize> <!-- Airport weather icons ================= --> <AirportWeather>true</AirportWeather> <AirportWeatherDetails>true</AirportWeatherDetails> <!-- Airspaces ================= --> <AirspaceCenter>true</AirspaceCenter> <AirspaceCenterText>true</AirspaceCenterText> <AirspaceFg>true</AirspaceFg> <AirspaceFgText>true</AirspaceFgText> <AirspaceFirUir>true</AirspaceFirUir> <AirspaceFirUirText>true</AirspaceFirUirText> <AirspaceIcao>true</AirspaceIcao> <AirspaceIcaoText>true</AirspaceIcaoText> <AirspaceOther>true</AirspaceOther> <AirspaceOtherText>true</AirspaceOtherText> <AirspaceRestricted>true</AirspaceRestricted> <AirspaceRestrictedText>true</AirspaceRestrictedText> <AirspaceSpecial>true</AirspaceSpecial> <AirspaceSpecialText>true</AirspaceSpecialText> <AirspaceFontScale>1</AirspaceFontScale> <!-- Airways ================= --> <Airway>true</Airway> <AirwayDetails>true</AirwayDetails> <AirwayIdent>true</AirwayIdent> <AirwayInfo>true</AirwayInfo> <AirwayWaypoint>true</AirwayWaypoint> <!-- Procedures (SID, STAR and approaches) ================= --> <Approach>true</Approach> <ApproachDetail>true</ApproachDetail> <ApproachText>true</ApproachText> <ApproachTextDetail>true</ApproachTextDetail> <!-- Enroute holdings ================= --> <Holding>true</Holding> <HoldingInfo>true</HoldingInfo> <HoldingInfo2>true</HoldingInfo2> <!-- ILS feathers ================= --> <Ils>true</Ils> <IlsDetail>true</IlsDetail> <IlsIdent>true</IlsIdent> <IlsInfo>true</IlsInfo> <!-- Markers ================= --> <Marker>true</Marker> <MarkerInfo>true</MarkerInfo> <MarkerSymbolSize>8</MarkerSymbolSize> <!-- Maximum text length before using elide ... ================= --> <MaximumTextLengthAirport>16</MaximumTextLengthAirport> <MaximumTextLengthAirportMinor>16</MaximumTextLengthAirportMinor> <MaximumTextLengthUserpoint>10</MaximumTextLengthUserpoint> <!-- Minimum airport runway length --> <MinRunwayLength>0</MinRunwayLength> <!-- Show MORA grid ================= --> <Mora>true</Mora> <!-- NDB ================= --> <Ndb>true</Ndb> <NdbIdent>true</NdbIdent> <NdbInfo>true</NdbInfo> <NdbRouteIdent>true</NdbRouteIdent> <NdbRouteInfo>true</NdbRouteInfo> <NdbSymbolSize>4</NdbSymbolSize> <!-- Online aircraft ================= --> <OnlineAircraft>true</OnlineAircraft> <OnlineAircraftText>true</OnlineAircraftText> <!-- Flight plan details ================= --> <RouteTextAndDetail>true</RouteTextAndDetail> <RouteTextAndDetail2>true</RouteTextAndDetail2> <RouteFontScale>1</RouteFontScale> <!-- Oceaninc tracks ================= --> <Track>true</Track> <TrackIdent>true</TrackIdent> <TrackInfo>true</TrackInfo> <TrackWaypoint>true</TrackWaypoint> <!-- Userpoints ================= --> <Userpoint>true</Userpoint> <UserpointInfo>true</UserpointInfo> <UserpointSymbolSize>12</UserpointSymbolSize> <!-- VOR ================= --> <Vor>true</Vor> <VorIdent>true</VorIdent> <VorInfo>true</VorInfo> <VorLarge>true</VorLarge> <VorRouteIdent>true</VorRouteIdent> <VorRouteInfo>true</VorRouteInfo> <VorSymbolSize>3</VorSymbolSize> <!-- Waypoints ================= --> <Waypoint>true</Waypoint> <WaypointName>true</WaypointName> <WaypointRouteName>true</WaypointRouteName> <WaypointSymbolSize>3</WaypointSymbolSize> <!-- Wind barbs ================= --> <WindBarbs>1</WindBarbs> <!-- At every degree, 2 = at every even degree grid point, etc. --> <WindBarbsSymbolSize>6</WindBarbsSymbolSize> </Layer> <!-- ============================================================================== Layer configurations. This first one is derived from default layer above. This means it receives all settings from default and modifies only a few selected ones. A small "MaximumRangeKm" value means closer zoom and vice versa. =================================================================================== --> <Layer MaximumRangeKm="0.2"> <AirportDiagramDetail3>false</AirportDiagramDetail3> <AirportMinorSymbolSize>20</AirportMinorSymbolSize> <AirportMsaSymbolScale>8</AirportMsaSymbolScale> <AirportSymbolSize>20</AirportSymbolSize> <MarkerSymbolSize>24</MarkerSymbolSize> <MaximumTextLengthAirport>30</MaximumTextLengthAirport> <MaximumTextLengthAirportMinor>30</MaximumTextLengthAirportMinor> <MaximumTextLengthUserpoint>30</MaximumTextLengthUserpoint> <NdbSymbolSize>30</NdbSymbolSize> <UserpointSymbolSize>28</UserpointSymbolSize> <VorSymbolSize>30</VorSymbolSize> <WaypointSymbolSize>14</WaypointSymbolSize> <WindBarbsSymbolSize>14</WindBarbsSymbolSize> </Layer> <!-- ============================================================================== Following layers are derived from their respective predecessor, i.e. "0.3" derives from "0.2". These change sizes, scales and disable (but not enable) features. =================================================================================== --> <Layer MaximumRangeKm="0.3"> <AirportMsaSymbolScale>7</AirportMsaSymbolScale> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="1"> <AiAircraftGroundText>false</AiAircraftGroundText> <AirportMsaSymbolScale>6</AirportMsaSymbolScale> <NdbSymbolSize>28</NdbSymbolSize> <VorSymbolSize>28</VorSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="2"> <AirportDiagramDetail2>false</AirportDiagramDetail2> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="5"> <AirportDiagramDetail>false</AirportDiagramDetail> <AirportMsaSymbolScale>5</AirportMsaSymbolScale> <MaximumTextLengthUserpoint>20</MaximumTextLengthUserpoint> <NdbSymbolSize>26</NdbSymbolSize> <UserpointSymbolSize>26</UserpointSymbolSize> <VorSymbolSize>26</VorSymbolSize> <WaypointSymbolSize>10</WaypointSymbolSize> <WindBarbsSymbolSize>13</WindBarbsSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="10"> <AiAircraftTextDetail3>false</AiAircraftTextDetail3> <AirportMinorSymbolSize>18</AirportMinorSymbolSize> <AirportMsaSymbolScale>4</AirportMsaSymbolScale> <AirportSymbolSize>18</AirportSymbolSize> <MarkerInfo>false</MarkerInfo> <MaximumTextLengthAirport>20</MaximumTextLengthAirport> <MaximumTextLengthAirportMinor>15</MaximumTextLengthAirportMinor> <NdbSymbolSize>24</NdbSymbolSize> <VorSymbolSize>24</VorSymbolSize> <WaypointSymbolSize>8</WaypointSymbolSize> <WindBarbsSymbolSize>12</WindBarbsSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="25"> <AiAircraftGround>false</AiAircraftGround> <AirportDiagram>false</AirportDiagram> <AirportMsaDetails>false</AirportMsaDetails> <NdbSymbolSize>22</NdbSymbolSize> <UserpointSymbolSize>24</UserpointSymbolSize> <VorSymbolSize>22</VorSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="50"> <AiAircraftTextDetail2>false</AiAircraftTextDetail2> <AiShipSmall>false</AiShipSmall> <AirportDiagramRunway>false</AirportDiagramRunway> <AirportMinorFontScale>0.9</AirportMinorFontScale> <AirportMinorInfo>false</AirportMinorInfo> <AirportMinorSymbolSize>16</AirportMinorSymbolSize> <AirportSymbolSize>16</AirportSymbolSize> <AirwayInfo>false</AirwayInfo> <ApproachTextDetail>false</ApproachTextDetail> <HoldingInfo2>false</HoldingInfo2> <IlsIdent>false</IlsIdent> <IlsInfo>false</IlsInfo> <Marker>false</Marker> <MaximumTextLengthAirport>10</MaximumTextLengthAirport> <MaximumTextLengthAirportMinor>8</MaximumTextLengthAirportMinor> <MaximumTextLengthUserpoint>10</MaximumTextLengthUserpoint> <NdbSymbolSize>20</NdbSymbolSize> <VorSymbolSize>18</VorSymbolSize> <WaypointName>false</WaypointName> <WaypointSymbolSize>6</WaypointSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="100"> <AirportInfo>false</AirportInfo> <AirportMinorFontScale>0.8</AirportMinorFontScale> <AirportMinorName>false</AirportMinorName> <AirportMinorSymbolSize>12</AirportMinorSymbolSize> <AirportSymbolSize>14</AirportSymbolSize> <HoldingInfo>false</HoldingInfo> <NdbInfo>false</NdbInfo> <NdbSymbolSize>16</NdbSymbolSize> <VorInfo>false</VorInfo> <VorSymbolSize>16</VorSymbolSize> <WaypointSymbolSize>3</WaypointSymbolSize> <WindBarbsSymbolSize>11</WindBarbsSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="150"> <AiAircraftTextDetail>false</AiAircraftTextDetail> <AirportName>false</AirportName> <AirportMinorFontScale>0.6</AirportMinorFontScale> <AirportOverviewRunway>false</AirportOverviewRunway> <AirportMinorSymbolSize>9</AirportMinorSymbolSize> <AirportSymbolSize>10</AirportSymbolSize> <AirwayIdent>false</AirwayIdent> <ApproachText>false</ApproachText> <IlsDetail>false</IlsDetail> <MaximumTextLengthUserpoint>8</MaximumTextLengthUserpoint> <NdbIdent>false</NdbIdent> <NdbSymbolSize>12</NdbSymbolSize> <UserpointSymbolSize>22</UserpointSymbolSize> <VorIdent>false</VorIdent> <VorLarge>false</VorLarge> <VorSymbolSize>12</VorSymbolSize> <Waypoint>false</Waypoint> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="250"> <AirportFontScale>0.9</AirportFontScale> <AirportMinorIdent>false</AirportMinorIdent> <AirportMinorSymbolSize>7</AirportMinorSymbolSize> <AirportSymbolSize>8</AirportSymbolSize> <AirspaceFontScale>0.95</AirspaceFontScale> <MinRunwayLength>2000</MinRunwayLength> <NdbSymbolSize>8</NdbSymbolSize> <OnlineAircraftText>false</OnlineAircraftText> <RouteFontScale>0.9</RouteFontScale> <UserpointSymbolSize>16</UserpointSymbolSize> <VorSymbolSize>8</VorSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="400"> <AiAircraftSize>26</AiAircraftSize> <AirportMinor>false</AirportMinor> <AirportRouteInfo>false</AirportRouteInfo> <AirspaceOtherText>false</AirspaceOtherText> <AirspaceRestrictedText>false</AirspaceRestrictedText> <AirspaceSpecialText>false</AirspaceSpecialText> <AirwayWaypoint>false</AirwayWaypoint> <Ils>false</Ils> <MinRunwayLength>4000</MinRunwayLength> <NdbSymbolSize>4</NdbSymbolSize> <UserpointInfo>false</UserpointInfo> <VorSymbolSize>6</VorSymbolSize> <WaypointRouteName>false</WaypointRouteName> <WindBarbsSymbolSize>10</WindBarbsSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="750"> <AiAircraftSize>24</AiAircraftSize> <AiShipLarge>false</AiShipLarge> <AirportMsa>false</AirportMsa> <AirspaceOther>false</AirspaceOther> <AirspaceRestricted>false</AirspaceRestricted> <AirspaceSpecial>false</AirspaceSpecial> <AirspaceFgText>false</AirspaceFgText> <AirspaceIcaoText>false</AirspaceIcaoText> <AirspaceFontScale>0.8</AirspaceFontScale> <AirwayDetails>false</AirwayDetails> <Holding>false</Holding> <MinRunwayLength>6000</MinRunwayLength> <Ndb>false</Ndb> <NdbRouteInfo>false</NdbRouteInfo> <UserpointSymbolSize>12</UserpointSymbolSize> <VorRouteInfo>false</VorRouteInfo> <VorSymbolSize>3</VorSymbolSize> <WindBarbsSymbolSize>9</WindBarbsSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="1200"> <AiAircraftSize>20</AiAircraftSize> <AiAircraftSmall>false</AiAircraftSmall> <AirportFontScale>0.8</AirportFontScale> <AirportMinorSymbolSize>6</AirportMinorSymbolSize> <AirportSymbolSize>6</AirportSymbolSize> <AirspaceFg>false</AirspaceFg> <AirspaceIcao>false</AirspaceIcao> <AirspaceCenterText>false</AirspaceCenterText> <Airway>false</Airway> <ApproachDetail>false</ApproachDetail> <MinRunwayLength>8000</MinRunwayLength> <RouteFontScale>0.8</RouteFontScale> <TrackInfo>false</TrackInfo> <Vor>false</Vor> <WindBarbs>2</WindBarbs> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="1800"> <AirportFontScale>0.6</AirportFontScale> <WindBarbs>3</WindBarbs> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="2400"> <AiAircraftSize>10</AiAircraftSize> <AiAircraftText>false</AiAircraftText> <AirportIdent>false</AirportIdent> <AirportMinorSymbolSize>4</AirportMinorSymbolSize> <AirportSymbolSize>4</AirportSymbolSize> <AirportWeather>false</AirportWeather> <AirportWeatherDetails>false</AirportWeatherDetails> <AirspaceCenter>false</AirspaceCenter> <AirspaceFontScale>0.75</AirspaceFontScale> <Mora>false</Mora> <NdbRouteIdent>false</NdbRouteIdent> <VorRouteIdent>false</VorRouteIdent> <TrackWaypoint>false</TrackWaypoint> <WindBarbsSymbolSize>8</WindBarbsSymbolSize> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="3600"> <WindBarbs>4</WindBarbs> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="4000"> <AiAircraftLarge>false</AiAircraftLarge> <AirportMinorSymbolSize>3</AirportMinorSymbolSize> <AirportSymbolSize>3</AirportSymbolSize> <RouteTextAndDetail>false</RouteTextAndDetail> <Approach>false</Approach> <RouteTextAndDetail2>false</RouteTextAndDetail2> </Layer> <!-- =================================================================================== --> <Layer MaximumRangeKm="6000"> <WindBarbs>8</WindBarbs> <AirportMinorSymbolSize>2</AirportMinorSymbolSize> <AirportSymbolSize>2</AirportSymbolSize> </Layer> <!-- =================================================================================== --> <!-- Distance cutoff limit. --> <Layer MaximumRangeKm="10000"> <WindBarbs>10</WindBarbs> <AirspaceFirUirText>false</AirspaceFirUirText> <AiAircraftLarge>false</AiAircraftLarge> </Layer> <!-- =================================================================================== --> <!-- Use very large range to always have a layer available with all drawing disabled. --> <Layer MaximumRangeKm="100000"> <Airport>false</Airport> <AirportNoRating>false</AirportNoRating> <AirspaceFirUir>false</AirspaceFirUir> <OnlineAircraft>false</OnlineAircraft> <Track>false</Track> <TrackIdent>false</TrackIdent> <Userpoint>false</Userpoint> <WindBarbs>0</WindBarbs> <!-- At no degree --> </Layer> </Layers> </MapLayerSettings> </LittleNavmap> ```
/content/code_sandbox/resources/config/maplayers.xml
xml
2016-07-04T21:23:50
2024-08-15T19:24:57
littlenavmap
albar965/littlenavmap
1,257
4,668
```xml import gql from 'graphql-tag'; import { types as emailTemplateTypes, queries as emailTemplateQueries, mutations as emailTemplateMutations, } from './schema/emailTemplate'; const typeDefs = async () => { return gql` scalar JSON scalar Date enum CacheControlScope { PUBLIC PRIVATE } directive @cacheControl( maxAge: Int scope: CacheControlScope inheritMaxAge: Boolean ) on FIELD_DEFINITION | OBJECT | INTERFACE | UNION ${emailTemplateTypes} extend type Query { ${emailTemplateQueries} } extend type Mutation { ${emailTemplateMutations} } `; }; export default typeDefs; ```
/content/code_sandbox/packages/plugin-emailtemplates-api/src/graphql/typeDefs.ts
xml
2016-11-11T06:54:50
2024-08-16T10:26:06
erxes
erxes/erxes
3,479
152
```xml <resources> <!-- Base application theme. --> <style name="AppTheme" parent="Theme.AppCompat.DayNight.NoActionBar"> <!-- Customize your theme here. --> <item name="colorPrimary">@color/primaryColor</item> <item name="colorPrimaryDark">@color/primaryColorDark</item> </style> </resources> ```
/content/code_sandbox/android/app/src/main/res/values/styles.xml
xml
2016-05-08T05:41:48
2024-08-15T07:25:47
zulip-mobile
zulip/zulip-mobile
1,274
76
```xml import { Modifier, EditorState } from 'draft-js'; import { MentionData } from '..'; import getSearchText from '../utils/getSearchText'; import getTypeByTrigger from '../utils/getTypeByTrigger'; export default function addMention( editorState: EditorState, mention: MentionData, mentionPrefix: string | ((trigger: string) => string), mentionTrigger: string, entityMutability: 'SEGMENTED' | 'IMMUTABLE' | 'MUTABLE' ): EditorState { const contentStateWithEntity = editorState .getCurrentContent() .createEntity(getTypeByTrigger(mentionTrigger), entityMutability, { mention, }); const entityKey = contentStateWithEntity.getLastCreatedEntityKey(); const currentSelectionState = editorState.getSelection(); const { begin, end } = getSearchText(editorState, currentSelectionState, [ mentionTrigger, ]); // get selection of the @mention search text const mentionTextSelection = currentSelectionState.merge({ anchorOffset: begin, focusOffset: end, }); let mentionReplacedContent = Modifier.replaceText( editorState.getCurrentContent(), mentionTextSelection, `${typeof mentionPrefix === 'string' ? mentionPrefix : mentionPrefix(mentionTrigger)}${mention.name}`, editorState.getCurrentInlineStyle(), entityKey ); // If the mention is inserted at the end, a space is appended right after for // a smooth writing experience. const blockKey = mentionTextSelection.getAnchorKey(); const blockSize = editorState .getCurrentContent() .getBlockForKey(blockKey) .getLength(); if (blockSize === end) { mentionReplacedContent = Modifier.insertText( mentionReplacedContent, mentionReplacedContent.getSelectionAfter(), ' ' ); } const newEditorState = EditorState.push( editorState, mentionReplacedContent, 'insert-fragment' ); return EditorState.forceSelection( newEditorState, mentionReplacedContent.getSelectionAfter() ); } ```
/content/code_sandbox/packages/mention/src/modifiers/addMention.ts
xml
2016-02-26T09:54:56
2024-08-16T18:16:31
draft-js-plugins
draft-js-plugins/draft-js-plugins
4,087
444
```xml <?xml version="1.0" encoding="utf-8"?> <FrameLayout xmlns:android="path_to_url" xmlns:app="path_to_url" android:orientation="vertical" android:layout_width="match_parent" android:layout_height="match_parent"> <TextView android:layout_width="wrap_content" android:layout_gravity="center" android:text="@string/settings" android:textSize="24sp" android:layout_height="wrap_content"/> <androidx.appcompat.widget.Toolbar android:id="@+id/toolbarSettings" android:layout_width="match_parent" android:layout_height="?attr/actionBarSize" android:theme="@style/ThemeOverlay.AppCompat.Dark.ActionBar" app:popupTheme="@style/AppTheme.NoActionBar.PopupOverlay" android:background="@color/colorPrimary" app:titleTextAppearance="@style/Toolbar_TextAppearance_White"/> </FrameLayout> ```
/content/code_sandbox/demo/src/main/res/layout/zhihu_fragment_fourth_settings.xml
xml
2016-02-23T08:54:55
2024-08-15T05:22:10
Fragmentation
YoKeyword/Fragmentation
9,719
199
```xml import { PolicyType } from "@bitwarden/common/admin-console/enums"; import { StateProvider } from "@bitwarden/common/platform/state"; import { GeneratorStrategy } from "../abstractions"; import { DefaultSubaddressOptions } from "../data"; import { EmailCalculator, EmailRandomizer } from "../engine"; import { newDefaultEvaluator } from "../rx"; import { SubaddressGenerationOptions, NoPolicy } from "../types"; import { observe$PerUserId, sharedStateByUserId } from "../util"; import { SUBADDRESS_SETTINGS } from "./storage"; /** Strategy for creating an email subaddress * @remarks The subaddress is the part following the `+`. * For example, if the email address is `jd+xyz@domain.io`, * the subaddress is `xyz`. */ export class SubaddressGeneratorStrategy implements GeneratorStrategy<SubaddressGenerationOptions, NoPolicy> { /** Instantiates the generation strategy * @param usernameService generates an email subaddress from an email address */ constructor( private emailCalculator: EmailCalculator, private emailRandomizer: EmailRandomizer, private stateProvider: StateProvider, private defaultOptions: SubaddressGenerationOptions = DefaultSubaddressOptions, ) {} // configuration durableState = sharedStateByUserId(SUBADDRESS_SETTINGS, this.stateProvider); defaults$ = observe$PerUserId(() => this.defaultOptions); toEvaluator = newDefaultEvaluator<SubaddressGenerationOptions>(); readonly policy = PolicyType.PasswordGenerator; // algorithm async generate(options: SubaddressGenerationOptions) { if (options.subaddressType == null) { options.subaddressType = "random"; } if (options.subaddressType === "website-name") { return this.emailCalculator.appendToSubaddress(options.website, options.subaddressEmail); } return this.emailRandomizer.randomAsciiSubaddress(options.subaddressEmail); } } ```
/content/code_sandbox/libs/tools/generator/core/src/strategies/subaddress-generator-strategy.ts
xml
2016-03-09T23:14:01
2024-08-16T15:07:51
clients
bitwarden/clients
8,877
405
```xml <?xml version="1.0" encoding="utf-8"?> <Project DefaultTargets="Build" ToolsVersion="15.0" xmlns="path_to_url"> <ItemGroup Label="ProjectConfigurations"> <ProjectConfiguration Include="Redist|ARM"> <Configuration>Redist</Configuration> <Platform>ARM</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Redist|ARM64"> <Configuration>Redist</Configuration> <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Redist|Win32"> <Configuration>Redist</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Redist|x64"> <Configuration>Redist</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_Spectre|ARM"> <Configuration>Static_Spectre</Configuration> <Platform>ARM</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_Spectre|ARM64"> <Configuration>Static_Spectre</Configuration> <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP_Spectre|ARM"> <Configuration>Static_WinXP_Spectre</Configuration> <Platform>ARM</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP_Spectre|ARM64"> <Configuration>Static_WinXP_Spectre</Configuration> <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP_Spectre|Win32"> <Configuration>Static_WinXP_Spectre</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP_Spectre|x64"> <Configuration>Static_WinXP_Spectre</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP|ARM"> <Configuration>Static_WinXP</Configuration> <Platform>ARM</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP|ARM64"> <Configuration>Static_WinXP</Configuration> <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP|Win32"> <Configuration>Static_WinXP</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_WinXP|x64"> <Configuration>Static_WinXP</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_Spectre|Win32"> <Configuration>Static_Spectre</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static_Spectre|x64"> <Configuration>Static_Spectre</Configuration> <Platform>x64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static|ARM"> <Configuration>Static</Configuration> <Platform>ARM</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static|ARM64"> <Configuration>Static</Configuration> <Platform>ARM64</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static|Win32"> <Configuration>Static</Configuration> <Platform>Win32</Platform> </ProjectConfiguration> <ProjectConfiguration Include="Static|x64"> <Configuration>Static</Configuration> <Platform>x64</Platform> </ProjectConfiguration> </ItemGroup> <PropertyGroup Label="Globals"> <VCProjectVersion>15.0</VCProjectVersion> <ProjectGuid>{EBA867AB-8D44-4BE2-AC16-ACEB357C69AA}</ProjectGuid> <Keyword>Win32Proj</Keyword> <RootNamespace>ConcRT</RootNamespace> <WindowsTargetPlatformVersion>$([Microsoft.Build.Utilities.ToolLocationHelper]::GetLatestSDKTargetPlatformVersion('Windows', '10.0'))</WindowsTargetPlatformVersion> </PropertyGroup> <Import Project="$(MSBuildThisFileDirectory)..\Shared.props" /> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" /> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|Win32'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SupportWinXP>true</SupportWinXP> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SupportWinXP>true</SupportWinXP> <WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|Win32'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> <SupportWinXP>true</SupportWinXP> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> <SupportWinXP>true</SupportWinXP> <WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|Win32'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|Win32'" Label="Configuration"> <ConfigurationType>DynamicLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <DisableStaticLibSupport>true</DisableStaticLibSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM'" Label="Configuration"> <ConfigurationType>DynamicLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <DisableStaticLibSupport>true</DisableStaticLibSupport> <WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|Win32'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> <WindowsSDKDesktopARMSupport>true</WindowsSDKDesktopARMSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|x64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SupportWinXP>true</SupportWinXP> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SupportWinXP>true</SupportWinXP> <WindowsSDKDesktopARM64Support>true</WindowsSDKDesktopARM64Support> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|x64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> <SupportWinXP>true</SupportWinXP> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> <SupportWinXP>true</SupportWinXP> <WindowsSDKDesktopARM64Support>true</WindowsSDKDesktopARM64Support> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|x64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <WindowsSDKDesktopARM64Support>true</WindowsSDKDesktopARM64Support> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|x64'" Label="Configuration"> <ConfigurationType>DynamicLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <DisableStaticLibSupport>true</DisableStaticLibSupport> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM64'" Label="Configuration"> <ConfigurationType>DynamicLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <DisableStaticLibSupport>true</DisableStaticLibSupport> <WindowsSDKDesktopARM64Support>true</WindowsSDKDesktopARM64Support> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|x64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM64'" Label="Configuration"> <ConfigurationType>StaticLibrary</ConfigurationType> <UseDebugLibraries>false</UseDebugLibraries> <PlatformToolset>v142</PlatformToolset> <WholeProgramOptimization>true</WholeProgramOptimization> <CharacterSet>Unicode</CharacterSet> <SpectreMitigation>Spectre</SpectreMitigation> <WindowsSDKDesktopARM64Support>true</WindowsSDKDesktopARM64Support> </PropertyGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" /> <ImportGroup Label="ExtensionSettings"> </ImportGroup> <ImportGroup Label="Shared"> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|Win32'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|Win32'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static|Win32'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Redist|Win32'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|Win32'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|x64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|x64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static|x64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Redist|x64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|x64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <ImportGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM64'" Label="PropertySheets"> <Import Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" /> <Import Project="$(SolutionDir)..\VC-LTL helper for Visual Studio.props" /> <Import Project="..\..\..\VC-LTL_Global.props" /> </ImportGroup> <PropertyGroup Label="UserMacros" /> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|Win32'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\WinXP\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|Win32'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(SpectreMitigation)\$(PlatformShortName)\WinXP\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|Win32'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|Win32'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>concrt140_ltl</TargetName> <OutDir>$(SolutionDir)..\Redist\$(VC-LTLUsedToolsVersion)\$(PlatformShortName)\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>concrt140_ltl</TargetName> <OutDir>$(SolutionDir)..\Redist\$(VC-LTLUsedToolsVersion)\$(PlatformShortName)\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|Win32'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(SpectreMitigation)\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(SpectreMitigation)\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|x64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\WinXP\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|x64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(SpectreMitigation)\$(PlatformShortName)\WinXP\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|x64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|x64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>concrt140_ltl</TargetName> <OutDir>$(SolutionDir)..\Redist\$(VC-LTLUsedToolsVersion)\$(PlatformShortName)\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>concrt140_ltl</TargetName> <OutDir>$(SolutionDir)..\Redist\$(VC-LTLUsedToolsVersion)\$(PlatformShortName)\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|x64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(SpectreMitigation)\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM64'"> <LinkIncremental>false</LinkIncremental> <IncludePath>$(SolutionDir)$(VC-LTLUsedToolsVersion)\vcruntime;$(SolutionDir)$(VC-LTLUsedToolsVersion);$(SolutionDir)ucrt\inc;$(SolutionDir);$(IncludePath)</IncludePath> <TargetName>libconcrt</TargetName> <OutDir>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(SpectreMitigation)\$(PlatformShortName)\Vista\</OutDir> </PropertyGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|Win32'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|Win32'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static|Win32'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0602;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Redist|Win32'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MinSpace</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_NO_DEFAULT_CONCRT_LIB;CONCRTDLL;_CRTBLD;_WIN32_WINNT=0x0601;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet> <MultiProcessorCompilation>true</MultiProcessorCompilation> <FavorSizeOrSpeed>Size</FavorSizeOrSpeed> <WholeProgramOptimization>true</WholeProgramOptimization> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> <ImportLibrary>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\concrt.lib</ImportLibrary> <AdditionalDependencies>msvcprt.lib;%(AdditionalDependencies)</AdditionalDependencies> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MinSpace</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_NO_DEFAULT_CONCRT_LIB;CONCRTDLL;_CRTBLD;_WIN32_WINNT=0x0602;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <MultiProcessorCompilation>true</MultiProcessorCompilation> <FavorSizeOrSpeed>Size</FavorSizeOrSpeed> <WholeProgramOptimization>true</WholeProgramOptimization> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> <ImportLibrary>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\concrt.lib</ImportLibrary> <AdditionalDependencies>msvcprt.lib;%(AdditionalDependencies)</AdditionalDependencies> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|Win32'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <EnableEnhancedInstructionSet>NoExtensions</EnableEnhancedInstructionSet> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0602;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;WIN32;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|x64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP|ARM64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0A00;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|x64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_WinXP_Spectre|ARM64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0A00;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static|x64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static|ARM64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0A00;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Redist|x64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MinSpace</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_NO_DEFAULT_CONCRT_LIB;CONCRTDLL;_CRTBLD;_WIN32_WINNT=0x0601;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <MultiProcessorCompilation>true</MultiProcessorCompilation> <FavorSizeOrSpeed>Size</FavorSizeOrSpeed> <WholeProgramOptimization>true</WholeProgramOptimization> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> <ImportLibrary>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\concrt.lib</ImportLibrary> <AdditionalDependencies>msvcprt.lib;%(AdditionalDependencies)</AdditionalDependencies> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Redist|ARM64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MinSpace</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_NO_DEFAULT_CONCRT_LIB;CONCRTDLL;_CRTBLD;_WIN32_WINNT=0x0A00;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <MultiProcessorCompilation>true</MultiProcessorCompilation> <FavorSizeOrSpeed>Size</FavorSizeOrSpeed> <WholeProgramOptimization>true</WholeProgramOptimization> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> <ImportLibrary>$(SolutionDir)..\VC\$(VC-LTLUsedToolsVersion)\lib\$(PlatformShortName)\Vista\concrt.lib</ImportLibrary> <AdditionalDependencies>msvcprt.lib;%(AdditionalDependencies)</AdditionalDependencies> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|x64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0601;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <ItemDefinitionGroup Condition="'$(Configuration)|$(Platform)'=='Static_Spectre|ARM64'"> <ClCompile> <PrecompiledHeader>NotUsing</PrecompiledHeader> <WarningLevel>Level3</WarningLevel> <Optimization>MaxSpeed</Optimization> <FunctionLevelLinking>true</FunctionLevelLinking> <IntrinsicFunctions>true</IntrinsicFunctions> <PreprocessorDefinitions>_CRT_DECLARE_GLOBAL_VARIABLES_DIRECTLY;_ALLOW_ITERATOR_DEBUG_LEVEL_MISMATCH;_WIN32_WINNT=0x0A00;_NO__LTL_Initialization;_DISABLE_DEPRECATE_LTL_MESSAGE;NDEBUG;_LIB;%(PreprocessorDefinitions)</PreprocessorDefinitions> <WholeProgramOptimization>false</WholeProgramOptimization> <ProgramDataBaseFileName>$(OutDir)$(TargetName).pdb</ProgramDataBaseFileName> <MultiProcessorCompilation>true</MultiProcessorCompilation> <RuntimeLibrary>MultiThreaded</RuntimeLibrary> <AdditionalOptions>/d2FH4 %(AdditionalOptions)</AdditionalOptions> </ClCompile> <Link> <SubSystem>Windows</SubSystem> <EnableCOMDATFolding>true</EnableCOMDATFolding> <OptimizeReferences>true</OptimizeReferences> <GenerateDebugInformation>true</GenerateDebugInformation> </Link> </ItemDefinitionGroup> <Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" /> <ItemGroup> <ClCompile Include="..\..\concrt\Agent.cpp" /> <ClCompile Include="..\..\concrt\CacheLocalScheduleGroup.cpp" /> <ClCompile Include="..\..\concrt\cds_cache_aligned_allocator.cpp" /> <ClCompile Include="..\..\concrt\Chores.cpp" /> <ClCompile Include="..\..\concrt\concurrent_hash.cpp" /> <ClCompile Include="..\..\concrt\concurrent_queue.cpp" /> <ClCompile Include="..\..\concrt\concurrent_vector.cpp" /> <ClCompile Include="..\..\concrt\Context.cpp" /> <ClCompile Include="..\..\concrt\ContextBase.cpp" /> <ClCompile Include="..\..\concrt\CurrentScheduler.cpp" /> <ClCompile Include="..\..\concrt\event.cpp" /> <ClCompile Include="..\..\concrt\Exceptions.cpp" /> <ClCompile Include="..\..\concrt\ExecutionResource.cpp" /> <ClCompile Include="..\..\concrt\ExternalContextBase.cpp" /> <ClCompile Include="..\..\concrt\FairScheduleGroup.cpp" /> <ClCompile Include="..\..\concrt\FreeThreadProxy.cpp" /> <ClCompile Include="..\..\concrt\FreeVirtualProcessorRoot.cpp" /> <ClCompile Include="..\..\concrt\HillClimbing.cpp" /> <ClCompile Include="..\..\concrt\InternalContextBase.cpp" /> <ClCompile Include="..\..\concrt\location.cpp" /> <ClCompile Include="..\..\concrt\Platform.cpp" /> <ClCompile Include="..\..\concrt\ppl.cpp" /> <ClCompile Include="..\..\concrt\RealizedChore.cpp" /> <ClCompile Include="..\..\concrt\ResourceManager.cpp" /> <ClCompile Include="..\..\concrt\rtlocks.cpp" /> <ClCompile Include="..\..\concrt\ScheduleGroupBase.cpp" /> <ClCompile Include="..\..\concrt\SchedulerBase.cpp" /> <ClCompile Include="..\..\concrt\SchedulerPolicyBase.cpp" /> <ClCompile Include="..\..\concrt\SchedulerProxy.cpp" /> <ClCompile Include="..\..\concrt\SchedulingNode.cpp" /> <ClCompile Include="..\..\concrt\SchedulingRing.cpp" /> <ClCompile Include="..\..\concrt\SearchAlgorithms.cpp" /> <ClCompile Include="..\..\concrt\staticinits.cpp" /> <ClCompile Include="..\..\concrt\SubAllocator.cpp" /> <ClCompile Include="..\..\concrt\TaskCollection.cpp" /> <ClCompile Include="..\..\concrt\TaskCollectionBase.cpp" /> <ClCompile Include="..\..\concrt\ThreadProxy.cpp" /> <ClCompile Include="..\..\concrt\ThreadProxyFactoryManager.cpp" /> <ClCompile Include="..\..\concrt\ThreadScheduler.cpp" /> <ClCompile Include="..\..\concrt\ThreadVirtualProcessor.cpp" /> <ClCompile Include="..\..\concrt\Timer.cpp" /> <ClCompile Include="..\..\concrt\Trace.cpp" /> <ClCompile Include="..\..\concrt\Transmogrificator.cpp" /> <ClCompile Include="..\..\concrt\TransmogrifiedPrimary.cpp" /> <ClCompile Include="..\..\concrt\UMSBackgroundPoller.cpp" /> <ClCompile Include="..\..\concrt\UMSFreeThreadProxy.cpp" /> <ClCompile Include="..\..\concrt\UMSFreeVirtualProcessorRoot.cpp" /> <ClCompile Include="..\..\concrt\UMSSchedulerProxy.cpp" /> <ClCompile Include="..\..\concrt\UMSSchedulingContext.cpp" /> <ClCompile Include="..\..\concrt\UMSThreadInternalContext.cpp" /> <ClCompile Include="..\..\concrt\UMSThreadProxy.cpp" /> <ClCompile Include="..\..\concrt\UMSThreadScheduler.cpp" /> <ClCompile Include="..\..\concrt\UMSThreadVirtualProcessor.cpp" /> <ClCompile Include="..\..\concrt\UMSWrapper.cpp" /> <ClCompile Include="..\..\concrt\utils.cpp" /> <ClCompile Include="..\..\concrt\VirtualProcessor.cpp" /> <ClCompile Include="..\..\concrt\VirtualProcessorRoot.cpp" /> <ClCompile Include="..\..\concrt\WinRTWrapper.cpp" /> <ClCompile Include="..\..\concrt\WorkQueue.cpp" /> </ItemGroup> <ItemGroup> <ResourceCompile Include="ConcRT.rc"> <ExcludedFromBuild Condition="'$(Configuration)'!='Redist'">true</ExcludedFromBuild> </ResourceCompile> </ItemGroup> </Project> ```
/content/code_sandbox/src/14.24.28314/Build/ConcRT/ConcRT.vcxproj
xml
2016-06-14T03:01:16
2024-08-12T19:23:19
VC-LTL
Chuyu-Team/VC-LTL
1,052
14,966
```xml import { useState, useEffect } from "react"; import { v4 as uuidv4 } from "uuid"; import { FliptEvaluationClient } from "@flipt-io/flipt-client-browser"; export default function Greeting() { const [data, setData] = useState<any | null>(null); useEffect(() => { async function fetchData() { try { const client = await FliptEvaluationClient.init("default", { url: process.env.NEXT_PUBLIC_FLIPT_ADDR ?? "path_to_url", }); const evaluation = client.evaluateVariant("language", uuidv4(), {}); console.log(evaluation); let language = evaluation.result?.variant_key; const greeting = language == "es" ? "Hola, from Next.js client-side" : "Bonjour, from Next.js client-side"; setData(greeting); } catch (err) { console.log(err); } } fetchData(); }); if (!data) return <p className="text-xl font-bold align-middle"> Loading... </p>; return <h1 className="text-3xl font-bold align-middle">{data}</h1>; } ```
/content/code_sandbox/examples/nextjs/components/Greeting.tsx
xml
2016-11-05T00:09:07
2024-08-16T13:44:10
flipt
flipt-io/flipt
3,489
249
```xml <?xml version="1.0" encoding="UTF-8"?> <definitions id="definitions" xmlns="path_to_url" targetNamespace="Examples"> <message id="myNewMessage" name="someNewMessage"/> <process id="simpleIntermediateEvent"> <startEvent id="theStart"/> <sequenceFlow id="flow1" sourceRef="theStart" targetRef="beforeNewCatchEvent"/> <userTask id="beforeNewCatchEvent"/> <sequenceFlow id="flow2" sourceRef="beforeNewCatchEvent" targetRef="intermediateNewCatchEvent"/> <intermediateCatchEvent id="intermediateNewCatchEvent"> <messageEventDefinition messageRef="myNewMessage"/> </intermediateCatchEvent> <sequenceFlow id="flow3" sourceRef="intermediateNewCatchEvent" targetRef="afterNewCatchEvent"/> <userTask id="afterNewCatchEvent"/> <sequenceFlow id="flow4" sourceRef="afterNewCatchEvent" targetRef="theEnd"/> <endEvent id="theEnd"/> </process> </definitions> ```
/content/code_sandbox/modules/flowable-engine/src/test/resources/org/flowable/engine/test/api/runtime/migration/simple-intermediate-message-catch-event.bpmn20.xml
xml
2016-10-13T07:21:43
2024-08-16T15:23:14
flowable-engine
flowable/flowable-engine
7,715
236
```xml <?xml version="1.0" encoding="UTF-8" ?> <!-- ~ ~ path_to_url ~ ~ Unless required by applicable law or agreed to in writing, software ~ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. --> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "path_to_url"> <mapper namespace="org.flowable.dmn.engine.impl.persistence.ChangeTenantDmn"> <!-- Historic Decision executions --> <select id="countChangeTenantIdHistoricDecisionExecutions" parameterType="map" resultType="long"> select count(RES.ID_) FROM ${prefix}ACT_DMN_HI_DECISION_EXECUTION RES <include refid="changeTenantIdDmnCriteriaSql" /> </select> <update id="changeTenantIdHistoricDecisionExecutions" parameterType="map"> update ${prefix}ACT_DMN_HI_DECISION_EXECUTION <if test="_databaseId != 'mssql'">RES</if> <set> TENANT_ID_ = #{targetTenantId, jdbcType=VARCHAR} </set> <if test="_databaseId == 'mssql'">FROM ${prefix}ACT_DMN_HI_DECISION_EXECUTION RES</if> <include refid="changeTenantIdDmnCriteriaSql" /> </update> <!-- Common SQL --> <sql id="changeTenantIdDmnCriteriaSql"> where <choose> <when test="sourceTenantId == null or sourceTenantId == ''">RES.TENANT_ID_ IS NULL OR RES.TENANT_ID_ = ''</when> <otherwise>RES.TENANT_ID_ = #{sourceTenantId, jdbcType=VARCHAR}</otherwise> </choose> <if test="definitionTenantId != null"> and RES.DECISION_DEFINITION_ID_ in ( select SUB.ID_ from ${prefix}ACT_DMN_DECISION SUB where <choose> <when test="definitionTenantId == ''"> SUB.TENANT_ID_ IS NULL OR SUB.TENANT_ID_ = ''</when> <otherwise>SUB.TENANT_ID_ = #{definitionTenantId, jdbcType=VARCHAR}</otherwise> </choose> ) </if> </sql> </mapper> ```
/content/code_sandbox/modules/flowable-dmn-engine/src/main/resources/org/flowable/dmn/db/mapping/ChangeTenantDmn.xml
xml
2016-10-13T07:21:43
2024-08-16T15:23:14
flowable-engine
flowable/flowable-engine
7,715
499
```xml import * as React from 'react'; import { CommitsHistoryLink } from 'features/versioning/commitsHistory'; import { CompareChangesLink } from 'features/versioning/compareChanges'; import { IRepository } from 'shared/models/Versioning/Repository'; import { IFullCommitComponentLocationComponents } from 'shared/models/Versioning/RepositoryData'; import Button from 'shared/view/elements/Button/Button'; import * as DataLocation from 'shared/models/Versioning/CommitComponentLocation'; import BranchesAndTagsListContainer from './BranchesAndTagsListContainer/BranchesAndTagsListContainer'; import RepositoryBreadcrumbs from './RepositoryBreadcrumbs/RepositoryBreadcrumbs'; import styles from './Toolbar.module.css'; type ILocalProps = { fullCommitComponentLocationComponents: IFullCommitComponentLocationComponents; repository: IRepository; } & Omit< React.ComponentProps<typeof BranchesAndTagsListContainer>, 'commitPointer' >; const Toolbar: React.FC<ILocalProps> = ({ repository, fullCommitComponentLocationComponents, ...branchesAndTagsListProps }) => { return ( <div className={styles.root}> <BranchesAndTagsListContainer repository={repository} {...branchesAndTagsListProps} commitPointer={fullCommitComponentLocationComponents.commitPointer} /> {!DataLocation.isRoot(fullCommitComponentLocationComponents.location) && ( <div className={styles.breadcrumbs}> <RepositoryBreadcrumbs repositoryName={repository.name} fullCommitComponentLocationComponents={ fullCommitComponentLocationComponents } /> </div> )} <div className={styles.actions}> <CompareChangesLink commitPointer={fullCommitComponentLocationComponents.commitPointer} repositoryName={repository.name} > {link => link && ( <div className={styles.action}> <Button to={link} size="small" theme="secondary"> Compare </Button> </div> ) } </CompareChangesLink> <div className={styles.action} /> <CommitsHistoryLink repositoryName={repository.name} commitPointer={fullCommitComponentLocationComponents.commitPointer} location={fullCommitComponentLocationComponents.location} > {link => link && ( <div className={styles.action}> <Button to={link} size="small" theme="secondary"> History </Button> </div> ) } </CommitsHistoryLink> </div> </div> ); }; export default Toolbar; ```
/content/code_sandbox/webapp/client/src/features/versioning/repositoryData/view/RepositoryData/Toolbar/Toolbar.tsx
xml
2016-10-19T01:07:26
2024-08-14T03:53:55
modeldb
VertaAI/modeldb
1,689
538