Skip to content

Fixes for deprecated functions #14

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 12, 2014
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 7 additions & 7 deletions TypeScriptCodeHints/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@
/*global define, brackets, $, window */

define(function (require, exports, module) {
"use strict";
"use strict";

var AppInit = brackets.getModule("utils/AppInit"),
CodeHintManager = brackets.getModule("editor/CodeHintManager"),
var AppInit = brackets.getModule("utils/AppInit"),
CodeHintManager = brackets.getModule("editor/CodeHintManager"),
Async = brackets.getModule("utils/Async"),
StringUtils = brackets.getModule("utils/StringUtils"),
_ = brackets.getModule("thirdparty/lodash"),
TypeScriptUtils = require("TypeScript/main").TypeScriptUtils,
TypeScriptService = require("TypeScript/main").TypeScriptService;

Expand Down Expand Up @@ -196,9 +196,9 @@ define(function (require, exports, module) {

// highlight the matched portion of each hint
if (index >= 0) {
var prefix = StringUtils.htmlEscape(hint.slice(0, index)),
match = StringUtils.htmlEscape(hint.slice(index, index + query.length)),
suffix = StringUtils.htmlEscape(hint.slice(index + query.length));
var prefix = _.escape(hint.slice(0, index)),
match = _.escape(hint.slice(index, index + query.length)),
suffix = _.escape(hint.slice(index + query.length));

$hintObj.append(delimiter + prefix)
.append($('<span>')
Expand Down
5 changes: 2 additions & 3 deletions TypeScriptCodeHints/unittests.js
Original file line number Diff line number Diff line change
Expand Up @@ -29,9 +29,9 @@ define(function (require, exports, module) {
"use strict";

var Editor = brackets.getModule("editor/Editor").Editor,
EditorManager = brackets.getModule("editor/EditorManager"),
FileUtils = brackets.getModule("file/FileUtils"),
DocumentManager = brackets.getModule("document/DocumentManager"),
MainViewManager = brackets.getModule("view/MainViewManager"),
SpecRunnerUtils = brackets.getModule("spec/SpecRunnerUtils"),
UnitTestReporter = brackets.getModule("test/UnitTestReporter"),
TypeScriptCodeHints = require("TypeScriptCodeHints/main");
Expand All @@ -51,8 +51,7 @@ define(function (require, exports, module) {

// Initialize EditorManager
var $editorHolder = $("<div id='mock-editor-holder'/>");
EditorManager.setEditorHolder($editorHolder);
EditorManager._init();
MainViewManager._initialize($editorHolder);
$("body").append($editorHolder);

// create Editor instance
Expand Down
2 changes: 0 additions & 2 deletions TypeScriptQuickEdit/main.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,10 +30,8 @@ define(function (require, exports, module) {

var AppInit = brackets.getModule("utils/AppInit"),
MultiRangeInlineEditor = brackets.getModule("editor/MultiRangeInlineEditor").MultiRangeInlineEditor,
FileIndexManager = brackets.getModule("project/FileIndexManager"),
EditorManager = brackets.getModule("editor/EditorManager"),
DocumentManager = brackets.getModule("document/DocumentManager"),
NativeFileSystem = brackets.getModule("file/NativeFileSystem").NativeFileSystem,
FileUtils = brackets.getModule("file/FileUtils"),
Async = brackets.getModule("utils/Async"),
TypeScriptUtils = require("TypeScript/main").TypeScriptUtils,
Expand Down
3 changes: 0 additions & 3 deletions TypeScriptQuickEdit/unittests.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,10 @@ define(function (require, exports, module) {

var CommandManager, // loaded from brackets.test
EditorManager, // loaded from brackets.test
FileIndexManager, // loaded from brackets.test
PerfUtils, // loaded from brackets.test
JSUtils, // loaded from brackets.test

FileUtils = brackets.getModule("file/FileUtils"),
NativeFileSystem = brackets.getModule("file/NativeFileSystem").NativeFileSystem,
SpecRunnerUtils = brackets.getModule("spec/SpecRunnerUtils"),
UnitTestReporter = brackets.getModule("test/UnitTestReporter"),
TypeScriptQuickEdit = require("TypeScriptQuickEdit/main");
Expand Down Expand Up @@ -160,7 +158,6 @@ define(function (require, exports, module) {
testWindow = w;
EditorManager = testWindow.brackets.test.EditorManager;
CommandManager = testWindow.brackets.test.CommandManager;
FileIndexManager = testWindow.brackets.test.FileIndexManager;
JSUtils = testWindow.brackets.test.JSUtils;
});

Expand Down