📝 Consistently mention what classes have global instances

This commit is contained in:
Kevin Sawicki 2014-02-04 10:06:37 -08:00
parent 43ba0b9529
commit ece269f158
10 changed files with 17 additions and 13 deletions

View File

@ -3,7 +3,7 @@ crypto = require 'crypto'
# Public: Represents the clipboard used for copying and pasting in Atom.
#
# A clipboard instance is always available under the `atom.clipboard` global.
# An instance of this class is always available as the `atom.clipboard` global.
module.exports =
class Clipboard
metadata: null

View File

@ -8,8 +8,7 @@ pathWatcher = require 'pathwatcher'
# Public: Used to access all of Atom's configuration details.
#
# A global instance of this class is available to all plugins which can be
# referenced using `atom.config`
# An instance of this class is always available as the `atom.config` global.
#
# ### Best practices
#

View File

@ -5,7 +5,8 @@ remote = require 'remote'
# Public: Provides a registry for commands that you'd like to appear in the
# context menu.
#
# Should be accessed via `atom.contextMenu`.
# An instance of this class is always available as the `atom.contextMenu`
# global.
module.exports =
class ContextMenuManager
# Private:

View File

@ -8,7 +8,7 @@ fs = require 'fs-plus'
# Public: Provides a registry for menu items that you'd like to appear in the
# application menu.
#
# Should be accessed via `atom.menu`.
# An instance of this class is always available as the `atom.menu` global.
module.exports =
class MenuManager
pendingUpdateOperation: null

View File

@ -6,6 +6,8 @@ path = require 'path'
# Public: Package manager for coordinating the lifecycle of Atom packages.
#
# An instance of this class is always available as the `atom.packages` global.
#
# Packages can be loaded, activated, and deactivated, and unloaded:
# * Loading a package reads and parses the package's metadata and resources
# such as keymaps, menus, stylesheets, etc.
@ -17,8 +19,6 @@ path = require 'path'
#
# Packages can also be enabled/disabled via the `core.disabledPackages` config
# settings and also by calling `enablePackage()/disablePackage()`.
#
# An instance of this class is globally available via `atom.packages`.
module.exports =
class PackageManager
Emitter.includeInto(this)

View File

@ -16,7 +16,7 @@ Git = require './git'
# Public: Represents a project that's opened in Atom.
#
# There is always a project available under the `atom.project` global.
# An instance of this class is always available as the `atom.project` global.
module.exports =
class Project extends Model
atom.deserializers.add(this)

View File

@ -8,10 +8,10 @@ Token = require './token'
# Public: Syntax class holding the grammars used for tokenizing.
#
# An instance of this class is always available as the `atom.syntax` global.
#
# The Syntax class also contains properties for things such as the
# language-specific comment regexes.
#
# There is always a syntax object available under the `atom.syntax` global.
module.exports =
class Syntax extends GrammarRegistry
Subscriber.includeInto(this)

View File

@ -10,7 +10,7 @@ File = require './file'
# Public: Handles loading and activating available themes.
#
# A ThemeManager instance is always available under the `atom.themes` global.
# An instance of this class is always available as the `atom.themes` global.
module.exports =
class ThemeManager
Emitter.includeInto(this)

View File

@ -16,6 +16,9 @@ Editor = require './editor'
# Public: The container for the entire Atom application.
#
# An instance of this class is always available as the `atom.workspaceView`
# global.
#
# ## Commands
#
# * `application:about` - Opens the about dialog.

View File

@ -7,8 +7,9 @@ PaneContainer = require './pane-container'
Pane = require './pane'
# Public: Represents the view state of the entire window, including the panes at
# the center and panels around the periphery. You can access the singleton
# instance via `atom.workspace`.
# the center and panels around the periphery.
#
# An instance of this class is always available as the `atom.workspace` global.
module.exports =
class Workspace extends Model
atom.deserializers.add(this)