Reformat and docs.
Correctly update project settings when the preferences change.

The `PropertyStore` class is a snapshot, and during the move to sbt 0.13 the storage
became a lazy-val, meaning we started to lose project settings.

Fixed #1001241
Fixed #1001267
Upgraded to the latest release version of AspectJ weaving.

Fixed #1001163.
Added FIXME note

If the ``companionActor`` is already dead (e.g, a VM Exception occurred at startup),
then the executing thread could be blocked forever.
Merge pull request #242 from dragos/issue/project-settings-1001241

Correctly update project settings when the preferences change.
Fixed ``TcpipSpy`` on Mac

It's pretty weird, but it looks like when the main TcpipSpy thread terminates, the
spawned ``in/outThread`` are also killed. This is extremely surprising, because
the ``TcpipSpy`` threads are not daemons!

Anyway, a couple of calls to ``join`` on the main Thread do the trick and now I
can spy on a remote debugging sessions. This is really useful!
Don't reuse a MarkOccurrences index if the global instance is not current anymore.

Cached indexes may survive longer than a presentation compiler (for instance, when compiler settings are
changed the presentation compiler restarts). This leads to wrong accesses to a "dead" compiler while using
the index.

Also switched to a weak reference in the cache. If there are many editors open, this can lead to
significant memory consumption (especially when the compiler is out-dated). Note that this is not
a memory leak, in the sense it won't grow unboundedly. As an optimization, we prefer to recompute
the index if the VM decides it needed to collect the index, instead of holding large chunks of
heap in the hope that it will still be useful.

Fixed #1001303.
Small refactoring in ``ScalaThread``

* Renamed ``ScalaThread.thread`` into ``ScalaThread.threadRef``
* No need to pass the ``threadRef`` to the ``ScalaThreadActor`` constructor.
Merge pull request #248 from dotta/refactoring/thread-ref

Small refactoring in ``ScalaThread``
Merge pull request #245 from dragos/issue/race-condition-1001303

Don't reuse a MarkOccurrences index if the global instance is not curren...
Merge pull request #247 from dotta/issue/fix-tcpipspy-on-mac

Issue/fix tcpipspy on mac
Fix #1001202 - Unable to set breakpoint in source attachment

It turns out that setting a breakpoint on a module declaration could sometime
fail badly (an error dialog was displayed to the user).

The reason why this fails is really simple, a call to
``CompilationUnitAdapter.getPackageDeclarations`` is performed while trying to
toggle the line breakpoint in the editor. And, because the existing
implementation of ``CompilationUnitAdapter.getPackageDeclarations`` used to
throw an ``UnsupportedOperationException``, it's not a surpise that this used
to fail badly.

The quick fix was to implement that method so that the ``PackageDeclaration``
for the opened classfile source is returned. And, in the specific case, the
``PackageDeclaration`` is only needed to find the raw package name, which is
why I have only implemented the ``getElementName`` (look at
``ToggleBreakpointAdapter.createQualifiedTypeName``, at some point you will see
a call to ``pd[0].getElementName();``, where ``pd`` is the
``PackageDeclaration``). This seems to be enough for fixing this specific
issue, and all considered, this fix can only improve on the status quo (simply
because the former implementation thrown an exception right away).

This PR doesn't come with test because the functionality is in the editor, and
we currently don't have a way to create UI tests.

That said, the whole logic we use to handle classfile sources looks a bit
broken.  First, why do we need ``ScalaClassFile`` to extend
``ScalaCompilationUnit``?  That does not quite make sense to me. And the fact
that the JDT ``ClassFile`` does not extend the JDT ``ICompilationUnit`` just
give one more indication that this is likely not needed. And, if we could make
``ScalaClassFile`` not to extends ``ScalaCompilationUnit``, we could then get
rid of the ``CompilationUnitAdapter``. I've been spending a bit of time looking
into this, but unfortunately I don't have time to experiment this any further
at the moment. I've pushed what I have
[here](https://github.com/dotta/scala-ide/tree/wip/classfile-not-a-compilation-unit),
it's not clean but it should give an idea of where I am heading with this (and
hopefully I'll work on this during my spare time some time in the future).
Merge pull request #246 from dotta/issue/unable-to-set-breakpoint-1001202

Fix #1001202 - Unable to set breakpoint in source attachment
Merge pull request #244 from dragos/issue/upgrade-ajdt-1001163

Upgraded to the latest release version of AspectJ weaving.
Logical structure works on 2.10

Added a version checker.
Added some JDI DSL to invoke methods and get field values.
Added logical structure tests.