31 Commits

Author SHA1 Message Date
Allan Odgaard
1ef78b3af7 Rename symbols to what’s expected by the 10.14 SDK 2019-06-29 20:14:15 +02:00
Allan Odgaard
79172d552e Set controlSize on NSControl instead of its cell 2018-11-17 20:20:55 +07:00
Allan Odgaard
e6ae59976b Remove most of our 10.10 compatibility checks 2018-10-30 12:31:51 +07:00
Allan Odgaard
f6fa273912 Update coding style for where to place colon after dictionary keys
This follows the Swift style and also makes it possible to align dictionary values using TextMate’s Align Assignments command.
2018-10-07 09:54:45 +02:00
Zev Eisenberg
3ba80810fc Fix part of speech. 2018-08-17 11:03:18 -04:00
Allan Odgaard
e70791ee89 Rename a bunch of constants to fix deprecation warnings (10.12) 2018-06-16 22:55:30 +02:00
Ronald Wampler
038acacca9 Avoid use of NSRunAlertPanel (10.9)
Although this is actually deprecated in 10.10, new APIs are available in 10.9 and it will make addressing deprecation warnings when upgrading to 10.10 easier.
2017-05-31 21:58:31 +02:00
Allan Odgaard
5caf3f789d Update build file generator
We no longer build frameworks as standalone targets but instead link it all together, which also means resources from “frameworks” will end up in the main bundle.

Currently the new build file generator does not create test targets and changing linker settings in frameworks is not inherited by the main target (since there is no naive way to “merge” framework specific linker settings).

For custom library dependencies (capnp, kj, and libressl) we specify them via `LIBS` using `/path/to/libfoo.a` so that the root target will inherit these dependencies and using the absolute path ensures that we get the static (rather than dynamic) version.
2016-11-06 16:49:46 +07:00
Allan Odgaard
383cae795d Move libressl include path to main target file
Although we only use the headers in a single framework, we generally do not use per-framework include paths and furthermore, by having it as a “global” setting, it’s much easier to change how TextMate is built (w/o having to analyzer compiler flags like `-I`).
2016-11-06 16:49:14 +07:00
mathbunnyru
440414f96c Use nullptr in all C++ files instead of NULL
This brings us a bit of extra type safety, for example where an integer is expected, nullptr should be disallowed by the compiler (unlike NULL).
2016-10-22 21:40:14 +07:00
Allan Odgaard
f78a3b2ce4 Use kCFAllocatorDefault instead of NULL 2016-10-22 16:29:19 +07:00
Allan Odgaard
26da9c7e15 Show “add license” titlebar buttons after one hour of use 2016-10-17 10:07:29 +02:00
Allan Odgaard
34db8d64ff Limit public API to the LicenseManager singleton 2016-10-17 10:07:29 +02:00
Allan Odgaard
5443b1b48f Add API to add a titlebar “add license” button 2016-10-17 10:07:29 +02:00
Allan Odgaard
fab0dc0da0 Move addLicense: method to LicenseManager 2016-10-17 10:07:29 +02:00
Allan Odgaard
682239e165 Do license revocation check on main thread
This should be a quick check, only done after entering a valid license, and the UI feedback depends on the result, so little was gained from doing it as a background check.
2016-10-17 10:07:29 +02:00
Allan Odgaard
644db44713 Introduce a “model” and bind to view controller’s represented object 2016-10-17 10:07:29 +02:00
Allan Odgaard
b4c2476508 Move “add license” window to license framework
Code has been refactored to using a view controller and there are now placeholder strings plus an “Online Shop” button.
2016-10-15 13:07:51 +02:00
Allan Odgaard
2feb4a497a Use crash_reporter_info_t’s convenience constructor
Also change most ‘crashInfo’ variable names to just ‘info’ to be consistent.
2016-10-07 22:14:33 +02:00
Allan Odgaard
f3a042aead Add some (crash reports) debug info to libressl usage
After switching to a version of libressl compiled from source I am seeing crashes from BIO_new_mem_buf and PEM_read_bio_RSA_PUBKEY.

Also minor code touchups, no functional change.
2016-07-16 13:27:57 +02: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
Allan Odgaard
60f125eedc Use proper deallocator for SecKeychainItemCopyAttributesAndData 2014-08-15 23:24:13 +02:00
Allan Odgaard
c1552d56bc Include some context in error message 2014-06-28 17:42:23 +02:00
Allan Odgaard
3a0adfb6bf Collect proper error code if SecItemCopyMatching fails 2014-06-28 17:42:22 +02:00
Allan Odgaard
39b94e6ac3 Harmonize whitespace and add trailing newline 2014-04-14 14:26:52 +07:00
Allan Odgaard
10c212cbd6 Improve error dialog when failing to add license 2013-06-22 21:02:45 +07:00
Allan Odgaard
f43414ae54 Don’t use kSecAttrCreator with keychain API
The creator code is obsolete and doesn’t serve much of a purpose, as we already mention TextMate in the service name.

When updating a keychain item we leave out kSecAttrLabel and kSecAttrComment, which may fix issue #1029.
2013-06-22 21:02:45 +07:00
Allan Odgaard
f01a9d9a71 Remove keychain argument
The new (non-deprecated) API no longer allows us to target a specific keychain for add, remove, and lookup.

This wasn’t used by TextMate itself but was extremely useful for writing tests against the API (using temporary keychains).
2013-06-19 11:55:32 +07:00
Allan Odgaard
c3f79e2e05 Improve code to find license key 2013-06-18 13:43:18 +07:00
Allan Odgaard
e1b3f71a69 Let about window show license (if any)
There is currently no way to add a TextMate (1.x) license to the key chain, but those who used TextMate r9147 or earlier should have one stored already.
2012-09-30 23:06:57 +02:00