Commit Graph

3581 Commits

Author SHA1 Message Date
Allan Odgaard
33f945eb02 Checkin release notes v2.0-beta.8.4 2015-12-06 20:12:23 +07:00
Allan Odgaard
78da1357fd File browser no longer refuses first responder on mouse clicks
Previously we would only accept first responder if clicking an already selected item, this was so that the user could select items in the file browser without losing focus from the text editor.

Unfortunately after switching to a view-based file browser, clicking an already selected item (even when the file browser does not have focus) brings up an edit-in-place text field which is undesired.

Worse is that it is brought up after a delay, so a user may for example click the file browser (to give it focus) and instantly initiates an action like duplicate, which brings up the edit-in-place text field for the new copy, but then after a short delay, will move the edit-in-place text field to the originally clicked item.
2015-12-06 19:56:57 +07:00
Allan Odgaard
b83f312e53 Remove dummy initializer method
With the 10.11 SDK we get a warning about this initializer not calling super, however, we do not intend for instances of this class to be created, which is why we had the dummy initializer.

We should remove this class entirely, as it’s a workaround for a problem that was fixed a long time ago, but I haven’t yet tested if there are still bundles using the (legacy) tm-file: URL scheme.
2015-11-20 13:33:01 +07:00
Allan Odgaard
edb38b0568 Refactor code to avoid overloading a system method
We were getting a warning because our method was called with nil, but the system method should be called with a non-nil argument.
2015-11-20 13:30:05 +07:00
Allan Odgaard
5af24f2c5e Call super’s init in designated initializer
This is to silence new warnings.
2015-11-20 13:25:02 +07:00
Allan Odgaard
bdbf82837f Add typecast to suppress warning with 10.11 SDK 2015-11-20 13:14:40 +07:00
Allan Odgaard
3478457098 Pass non-null arguments where the 10.11 SDK requires it 2015-11-20 13:12:16 +07:00
Allan Odgaard
bef024c73c Support using “force click” to look up words
This must be set in System Preferences → Trackpad → Look up & data detectors.
2015-11-19 22:34:54 +07:00
Allan Odgaard
edf2923f3a Allow obtaining character rectangle placed on the baseline 2015-11-19 22:29:27 +07:00
Allan Odgaard
8c19532531 Don’t change user defaults in background queue
The problem is that when we change user defaults a notification is posted, and this runs on the thread that did the change, so our own “user defaults did change” notification callbacks are executed on a background thread.
2015-11-18 09:57:29 +07:00
Allan Odgaard
1e10ef8ac2 Workaround for 10.11 regression 2015-11-18 09:57:29 +07:00
Allan Odgaard
bdcba4d66e Change --amend option to --commit-button-title Amend
This allows us to set arbitrary titles, should we need it in the future.

It also changes the code slightly so that there is only one method to create the full button title.
2015-10-29 09:30:23 +07:00
Allan Odgaard
e1bbc9f358 Change --rebase-in-progress option to --show-continue-button
Also change the property accordingly.
2015-10-29 09:03:16 +07:00
Jacob Carlborg
d988cf18c2 Support "Amend" as button title in the commit window
When the --amend flag is passed to the "commit" command, the commit
window will used "Amend" instead of "Commit" as the title for the
commit button.
2015-10-29 08:54:06 +07:00
Jacob Carlborg
cc7e2e8322 Add support for commit and continue in the commit window
The use case for this feature is when an interactive rebase is in
progress and be able to, in one command, amend the current commit
and continue with rebase.

By default, if the --rebase-in-progress flag is passed when the
"commit" command is invoked the commit button will be in a
"commit and continue" state. This is indicated by the title of the
commit button now being "Commit & Continue". If the option (⌥) key
is being hold down the state will revert back to the standard "commit"
state and the title will change to "Continue".

If the butten was clicked when it was in the "commit and continue"
state the "commit" command will print "TM_SCM_COMMIT_CONTINUE=1"
(without the quotes) to stdout as the last line. If the button was
clicked when it was in the standard "commit" state the output may
contain "TM_SCM_COMMIT_CONTINUE=0", or the "TM_SCM_COMMIT_CONTINUE"
string will be absent.
2015-10-29 08:54:06 +07:00
Allan Odgaard
8d8c539313 Truncate environment variables that exceed ARG_MAX
Previously we only logged an error when this happened, but (recently?) exceeding the limit will cause execve().
2015-10-28 15:38:18 +07:00
Allan Odgaard
57d0f29cdc Replace in folder would lose byte-order-mark for UTF-8 documents
This would only happen for documents not already open when performing the search and replace (in folder).
2015-10-28 15:37:04 +07:00
Allan Odgaard
b55ef5b09a Save all xibs with Xcode 7.1 (7B91b)
This was done in an attempt to prevent the warning saying “This file is set to build for a version older than the project deployment target.”

Unfortunately saving all the xibs did not get rid of the warning, even though tehy are all set to have 10.7 as their build target.

The latest xib format does however remove about 10.000 lines of XML.
2015-10-26 23:26:17 +07:00
Allan Odgaard
3dbdd0cf32 Checkin release notes 2015-10-26 23:26:16 +07:00
Allan Odgaard
9490ff8967 Don’t re-use FSItems for expanded folders during reload
The problem is that the URL property for all descendents of this item are pointing to the old path.

Ideally we should recursively update the descendents, because the current workaround loses the expanded state of the folder.
2015-10-23 17:21:41 +07:00
Allan Odgaard
1cdf087e96 Reset target property when re-using file system item 2015-10-23 17:20:54 +07:00
Ronald Wampler
00a20aefb6 Revert "Disable unused-local-typedef warning for sparsehash"
This reverts commit 2c6ad9b391.

Upstream released a new version, which resolved the warnings this commit meant to suppress.
2015-10-22 16:27:40 +07:00
Allan Odgaard
c8fce64ad6 Account for NSOutlineView expand animations when revealing item
To reveal an item we need to expand all parents, but after switching to a view-based outline view, expanding items will be done animated, and updating the outline view’s bounds won’t happen until after all animation has completed.

I tried adding a completion handler to the current animation context, but this ran before the bounds had been updated.

I also tried to disable expansion animation (when we have an item to reveal), but I was unable to make that work. What I did was group the expandItem:expandChildren: call in a new animation context for which the duration had been set to zero.
2015-10-18 10:34:53 +07:00
Allan Odgaard
cb75d41db3 Prevent opening two tabs for the same file
This could previously be done by creating a symbolic link and then selecting both the symbolic link and the original file, and selecting to open both at once.

Since the two tabs would have same identifier, the NSView for one of the two tabs could be left behind in the tab bar when manipulating the tabs.
2015-10-17 17:42:19 +07:00
Allan Odgaard
1597e68714 Do not show ‘0’ when holding command (⌘) in search results
The numbers indicate the key equivalent that can be used to jump to the document, but since cb1c516 we no longer support ⌘0.
2015-10-16 20:02:24 +07:00
Allan Odgaard
7719097bdd Add View → Font → Default Size menu action
This also works for the HTML output.
2015-10-16 19:53:16 +07:00
Allan Odgaard
e621685fc1 Add makeTextStandardSize: action method 2015-10-16 19:53:16 +07:00
Allan Odgaard
cb1c51692c Bind Go to Tab → Last Tab to ⌘9 instead of ⌘0
Also avoid binding to ⌘0 in all other ⌘1-n contexts.

This frees up ⌘0 to “Reset Font Size”.
2015-10-16 19:52:47 +07:00
Allan Odgaard
9a1e05f489 Showing bundle menu with no status bar would cause infinite loop
This is because we were forwarding the message to ‘nil’ rather than the status bar, and ‘nil’ here would be first responder, i.e. ourself.

Fixes textmate/bugs#17
2015-10-16 19:14:36 +07:00
Michael Sheets
b06f20ca72 Add project scope for Cargo (Rust) projects (attr.project.cargo) 2015-10-10 19:30:22 -05:00
Allan Odgaard
720f9eac98 Expect more than just {?name} in GitHub’s URI template
Currently GitHub supports both name and label parameters.
2015-10-03 17:33:21 +07:00
Allan Odgaard
26d4ebf302 Decompile .scpt files when generating QuickLook preview/thumbnail 2015-10-03 17:33:21 +07:00
Allan Odgaard
5738792b36 Refactor QuickLook generator
Generating a preview and a thumbnail now share the same code for loading the file and creating an attributed string from its content.
2015-10-03 17:33:21 +07:00
Ronald Wampler
054747974b Refresh when unfolding on mouse down event
This seems to be necessary when the document occupies less space than the visible document window.
2015-10-03 17:33:21 +07:00
Ronald Wampler
a23b5225b1 Don't undefine/redefine "DEPRECATED" macro
We no longer use Apple's headers for `openssl` so this isn't necessary.
2015-10-03 17:33:21 +07:00
Ronald Wampler
5bbcf42487 Require LibreSSL instead of relying on the system provided openssl
Apple deprecated `openssl` in 10.7 and the headers are now removed in 10.11. Since we use some low level functions that are not provided in Apple's crypto frameworks, we now require are own version.
2015-10-03 17:33:21 +07:00
Ram Nadella
acd4497f5e Fix typo in 2015-09-16 (v2.0-beta.8) section of release notes 2015-10-03 17:10:47 +07:00
Allan Odgaard
cd016be294 Update dialog plug-in (declare new protocols from 10.11 SDK) 2015-09-24 18:33:40 +07:00
Ronald Wampler
3f5575cfe4 Directly convert the URL received from NSOpenPanel to a path
We call `fileURL` here but the method doesn't actually exists (it's actually a property with the getter `isFileURL`). The URLs we obtain from NSOpenPanel are paths so it's probably safe to get the path without checking if it's a proper file URL.
2015-09-21 09:50:49 -04:00
Ronald Wampler
75d3c74f05 OFBOutlineView: Rename draggedItems → draggedOFBItems
This property's name was conflicting with a private instance variable in our superclass (NSOutlineView) for the 10.11 SDK.
2015-09-21 09:50:49 -04:00
Ronald Wampler
f29ddf6500 Declare new protocols when building for 10.11
These were informal protocols prior to 10.11.
2015-09-21 09:50:20 -04:00
Ronald Wampler
9e4e88ce76 Explicitly cast back to the CGEventFlags typedef
The SDK for 10.11 (Xcode 7 GM and Xcode 7.1 beta) declares this enum using CF_ENUM instead of CF_OPTIONS, which forces us to explicitly cast back to the typedef type. <rdar://22743357>

Hopefully, we can revert this after OS 10.11 is officially released.
2015-09-21 09:50:04 -04:00
Allan Odgaard
64b03394e9 Checkin release notes v2.0-beta.8 2015-09-16 08:35:15 +02:00
Allan Odgaard
10b1f3bfea Always clear SCM info when changing document
For a project window where only some tabs are under version control, switching from one tab with version control info, to one without, would use the info from the previous tab with the new one (proxy icon badge and scope attributes).
2015-09-10 14:24:28 +02:00
Allan Odgaard
b6a7529d97 Bind tab size dialog to OakDocumentView instead of OakTextView
This ensures the setting is saved and also (sort of) follows the principle of least knowledge.
2015-09-10 14:20:51 +02:00
Allan Odgaard
871e013ed9 Add tabSize property to OakDocumentView
Going via this property ensures that the setting is saved.
2015-09-10 14:19:10 +02:00
Allan Odgaard
b1fa6524cb Save with Xcode Version 6.4 (6E35b) 2015-09-10 13:06:36 +02:00
Allan Odgaard
a99acf8532 fixup! Ensure we re-use file browser items that are unchanged v2.0-beta.7.12 2015-09-07 20:15:10 +02:00
Allan Odgaard
98571f90ee Update Onigmo submodule v2.0-beta.7.11 2015-09-07 18:27:16 +02:00
Allan Odgaard
c038bbe7bc Ensure we re-use file browser items that are unchanged
The data sources should already re-use items, as they are passed the old items, but since data sources are multi threaded, there might perhaps be a situation where the items passed gets updated out-of-order and re-use isn’t perfect (I haven’t been able to confirm this).

Re-using the items, when we use the animation methods of the outline view, does however seem to be very important, because the outline view will neither copy nor retain the items returned from our data source, so we must ensure they stay retained until we have told the outline view that the item no longer exist, so replacing an item with one that is equal but not pointer identical, without notifying the outline view, will cause random crashes.

At least that is my theory.
2015-09-07 18:16:58 +02:00