Aditya Bhatt
46f89dbe6f
Use a bit more specific signals for styleChanged and styleDeleted. Make
...
the paragraphStyles selector dynamically add/remove styles instead of
reloading everytime. Pass style name in signal argument.
2013-02-18 14:41:31 +05:30
Aditya Bhatt
f6e2edcdd4
Add style change signals
2013-02-01 23:57:31 +05:30
Jos van den Oever
9b0992dffb
Remove unneeded closure.
...
And some whitespace fixes.
2012-11-09 21:48:55 +01:00
Friedrich W. H. Kossebau
549dd93381
Turn setting the style of a paragraph into an operation (dirty initial hack)
2012-11-09 12:24:35 +01:00
Friedrich W. H. Kossebau
51570c2838
Unbreak styles combobox in programs/editor
...
Also
* emit signal for cursor move again
* turn signal names into string objects
* makes Session and Document take odfCanvas instead of just odfContainer
2012-11-09 12:21:08 +01:00
Friedrich W. H. Kossebau
a058242e6b
Split ops.Document from ops.Session (initial step)
...
Idea here is to create abstraction as much as possible for all ODF-related
objects, e.g. the cursor objects now belong to and know the ODF document model
they run around in.
Some avatar tests still need fixing/adaption, but from manually testing it
looks good, so commiting now to prevent too much differences.
2012-11-09 12:19:08 +01:00
Friedrich W. H. Kossebau
0a056bcae5
Move selectionMover and selection from caret into cursor
...
Breaks a few unit tests for now (due to changed API), but still works in the browser
2012-11-09 12:18:17 +01:00
Friedrich W. H. Kossebau
19945005ab
Rename signals from "avatar/*" to "cursor/*"
2012-11-09 12:13:33 +01:00
Friedrich W. H. Kossebau
8369aacb78
Make closure compiler happy (well, she better than us)
2012-11-09 12:13:22 +01:00
Friedrich W. H. Kossebau
a788288991
Create a simple RemoveText operation on backspace
2012-11-09 12:13:04 +01:00
Jos van den Oever
47a0f22140
Fix positioning and fix inserting text in empty nodes.
2012-11-09 12:11:59 +01:00
Jos van den Oever
f7933c05bb
Fix bug where the new text node is inserted in the wrong place.
2012-11-09 12:11:55 +01:00
Jos van den Oever
94f2ed95c4
The nodeOffset should be zero when checking if the position is just before a cursor.
2012-11-09 12:11:52 +01:00
Jos van den Oever
2c0b19273e
if the position is just after a cursor, then move in front of that cursor
2012-11-09 12:11:44 +01:00
Jos van den Oever
c48dbedf53
Fix check in filter.acceptPosition.
...
It returns 1 if it accepts.
2012-11-09 12:11:34 +01:00
Jos van den Oever
bb7d9fc3d8
Remove unneeded function.
2012-11-09 12:11:29 +01:00
Jos van den Oever
a85093903b
Modify text insertion to use offset from root node.
2012-11-09 12:11:10 +01:00
Friedrich W. H. Kossebau
10b48a48a5
Move creation and housekeeping of the cursor objects to the world of SessionImplementation
2012-11-09 12:07:24 +01:00
Tobias Hintze
3653e13a42
implement OperationFactory and NowjsOperationRouter; add spec() to ops
2012-11-09 12:00:43 +01:00
Tobias Hintze
cd5b09f731
create TrivialOperationRouter
2012-11-09 11:59:15 +01:00
Friedrich W. H. Kossebau
6c785c38d9
Move implementation of SessionImplementation.moveMemberCaret into OpMoveMemberCursor
2012-11-09 11:58:17 +01:00
Friedrich W. H. Kossebau
36b6891d14
Remove SessionImplementation.getLocalMemberid, should not be a property of the session object
2012-11-09 11:57:36 +01:00
Friedrich W. H. Kossebau
add136763c
Create OpRemoveMember for removing cursors/avatars
2012-11-09 11:57:23 +01:00
Friedrich W. H. Kossebau
b69a7d94ac
Restore old text input state, but now with SessionController and OpInsertText
2012-11-09 11:56:19 +01:00
Friedrich W. H. Kossebau
fb46e0b011
Move click handling to SessionController (with a workaround for no cursors yet in Session object)
2012-11-09 11:55:40 +01:00
Tobias Hintze
91d80781a9
remove verbosity
2012-11-09 11:49:06 +01:00
Tobias Hintze
b45ad3218a
rename (Trivial)UserModel.myMemberId to getLocalMemberId and use it in session
2012-11-09 11:48:58 +01:00
Tobias Hintze
316c89f218
SessionImplementation: events-subscribe cleanup
2012-11-09 11:48:29 +01:00
Friedrich W. H. Kossebau
97e0e41a28
Move home of avatars into SessionView
...
Temporarily disables click handling
2012-11-09 11:48:07 +01:00
Friedrich W. H. Kossebau
a728da8fbc
turn avatar factory method into own class gui.AvatarFactory
2012-11-09 11:46:39 +01:00
Tobias Hintze
4e4e5b1658
TrivialUserModel
2012-11-09 11:44:34 +01:00
Tobias Hintze
690f8a86a8
SessionImplementation: remove obsolete addEditingAvatar (now a Op)
2012-11-09 11:40:39 +01:00
Tobias Hintze
768bc1094c
SessionImplementation: declare events
2012-11-09 11:31:11 +01:00
Tobias Hintze
b0d1305496
add event system to SessionImplementation (emit/subscribe)
2012-11-09 11:27:46 +01:00
Tobias Hintze
1467184ebb
SessionImplementation: remove obsolete createAvatar function
2012-11-09 11:27:41 +01:00
Friedrich W. H. Kossebau
def456a6ca
Extract creation of avatar from SessionImplementation.addMemberToSession into factory method
...
for now just test.js, breaks other usages of SessionImplementation
2012-11-09 11:27:11 +01:00
Tobias Hintze
f4ad9986c6
wip-snapshot: start factory passing
2012-11-09 11:18:47 +01:00
Tobias Hintze
c2abff25a0
first bits of refactoring SessionController / SessionImplementation
2012-11-09 11:14:10 +01:00
Jos van den Oever
8b428e2bc6
If the offset is zero and there is no TextNode, create one.
2012-10-23 15:07:56 +02:00
Aditya Bhatt
4371098d19
lint
2012-10-23 12:44:17 +02:00
Aditya Bhatt
7b0261ea00
True user tracking involves both cursor and focus tracking. Add avatarActivated event and use it in the paragraphStyles selector, so that when you click on another avatar, it's paragraph is selected
2012-10-23 12:32:26 +02:00
Aditya Bhatt
6e5caa6a27
Merge branch 'collaborate' of gitorious.org:webodf/webodf into collaborate
2012-10-23 12:12:05 +02:00
Aditya Bhatt
24c79a2ab8
Fix conflict and methodify getActiveAvatar
...
Conflicts:
webodf/lib/ops/SessionImplementation.js
2012-10-23 12:09:39 +02:00
Jos van den Oever
3db5eed7c5
Avoid text being added to the Caret when typing.
2012-10-23 11:42:38 +02:00
Jos van den Oever
e29a11c786
Change getFocussedAvatar to getActiveAvatar and make it return the right value.
2012-10-23 10:11:35 +02:00
Jos van den Oever
d5705f6fc7
Make the active avatar a member of SessionImplementation state.
...
also fix some whitespace and other JSlint problems and add some function signatures.
2012-10-23 10:07:20 +02:00
Aditya Bhatt
5edb34ce38
add active avatar logic
2012-10-23 09:57:05 +02:00
Aditya Bhatt
c2828f9d7f
Merge branch 'collaborate' of gitorious.org:webodf/webodf into collaborate
2012-10-22 16:39:16 +02:00
Aditya Bhatt
cb67594780
Use memberMoveCaret instead of just move() on mouse click, so we have one unified gateway to move carets. Fire an event containing the avatar's info whenever the avatar moves for others to intercept
2012-10-22 16:34:27 +02:00
Jos van den Oever
e966700c7a
Implement getPositionInTextNode.
2012-10-22 15:01:46 +02:00