Skip to content

Simulated Primitives

abstraktor edited this page May 15, 2015 · 4 revisions

Prims we already simulate

  • ExternalCall: BitBltPlugin copyBits (with simulateCopyBits or copyBitsSimulated)
  • ExternalCall: BitBltPlugin warpBits (with warpBitsSimulated:sourceMap:
  • ExternalCall: B2DPlugin balloon primitives (with simulateBalloonPrimitive:args:)

Prims we could simulate

  • snapshotPrimitive: 97
  • snapshotEmbeddedPrimitive: 247
  • imageName:
  • monticello prims
  • display host window
  • some of the primitives that are having "Optional." in their comment
  • primitiveDirectoryEntry with primLookupEntryIn:name: (didn't closely look at it yet)

Prims we can't simulate

  • FilePlugin (primitiveDirectoryDelete, primitiveDirectoryCreate)
  • Sockets

Finding optional primitives

some are marked optional, but actually mean "one out of several optional prims must be implemented"

((SystemNavigation new allMethodsWithSourceString: 'Optional' matchCase: true)
	select: [:method | (Pragma allNamed: #primitive: in: method actualClass)
	anySatisfy: [ :classPrimPragma | classPrimPragma selector = method selector ]])
	inspect