140 Commits

Author SHA1 Message Date
Erik Faye-Lund
5b120b11f5 editor: const correctness 2012-04-10 18:31:48 +02:00
Erik Faye-Lund
96cc9e82a4 editor: do not ask for saving on new document
A new, unmodified document does not contain any interresting data,
let's not bother the user about saving before quitting in that
case.

fixup some code style while at it.
2012-04-10 18:31:46 +02:00
Erik Faye-Lund
b85a3bddcb edior: use document-getter more consistently 2012-04-10 18:31:39 +02:00
Erik Faye-Lund
8f94efbc62 player: add suport for Win64 builds
To make sure it works, add support to the example while we're at
it. Also fix compilation warnings.
2012-03-01 14:27:55 +01:00
Erik Faye-Lund
d8081fd63c editor: fix dialog return
return the status from EndDialog instead of a constant TRUE. This
is mostly about keeping the code "honest", it doesn't change
anything in reality.

Also fix up some code-style.
2011-04-05 10:01:45 +02:00
Erik Faye-Lund
6d56c23e00 editor: use Set/GetDlgItemInt
We previously rolled our own text <-> int conversion code for
the dialogs. Use winapi's built-in one instead.

While we're at it, fix some indentation and a return-code.
2011-04-05 09:58:44 +02:00
Erik Faye-Lund
341bf3b449 editor: initialize the correct field
biasSelectionDialogProc deals with IDC_BIASSELECTION_-stuff, not
IDC_SETROWS_-stuff. Initialize the edit-controller to 0 as expected.
2011-04-05 09:48:54 +02:00
Erik Faye-Lund
0a4d46d267 editor: fix compilation of debug build 2011-04-02 15:28:44 +02:00
Erik Faye-Lund
3178f22c2a editor: replace document when loading
Simplify the book-keeping a bit by simply creating a new document
when loading. Copy the ClientSocket to the new document to keep
client-state.
2011-03-29 20:24:41 +02:00
Erik Faye-Lund
9132474bdb editor: clear clientTracks on disconnection 2011-03-28 23:15:08 +02:00
Erik Faye-Lund
558dcf01fb editor: pass track-name to client-socket
This makes ClientSocket independent of the track-order in the
SyncDocument, and makes it easier to understand quite a bit
of the logic.
2011-03-28 23:12:25 +02:00
Erik Faye-Lund
55cdc24cef editor: move fileName inside SyncDocument 2011-03-28 22:59:44 +02:00
Erik Faye-Lund
8de60a4095 editor: error our gracefully when loading fails
If an error happens while loading, the old document should be left
intact. Ensure this by not modifying the document until all loading
code has been run.
2011-03-28 22:59:44 +02:00
Erik Faye-Lund
9724884884 editor: move all client stuff to socket-class
Rename NetworkSocket to ClientSocket, and put the client-specific
functionality in it.
2011-03-28 22:59:37 +02:00
Erik Faye-Lund
bc5fcca75f editor: propagate allocation-errors
This isn't really a big deal, but let's just propagate allocation
errors as std::bad_alloc exceptions.
2011-01-26 21:21:30 +01:00
Erik Faye-Lund
687df0876b protocol: make client-index implicit
This will enable us to unify the code in a later commit.

This is a protocol-breaking change, and means that matching editor
and player must be used.
2011-01-25 23:36:15 +01:00
Erik Faye-Lund
7590f5c6c6 Merge branch 'work/icon' 2010-11-23 22:00:33 +01:00
Erik Faye-Lund
8c842edff3 editor: add an application icon
The ICO was created from contrib/logo.svg by exporting a PNG from
Inkscape, and converting the PNG online at with iconverticons.com
2010-11-17 23:18:42 +01:00
Erik Faye-Lund
5318b90d7a editor: delete remote keys when creating new document 2010-11-13 14:06:26 +01:00
Erik Faye-Lund
2827d4b4dc editor: reorder file-list
Update the file-list in the order Visual Studio prefers it to be. This
reduces update-noise when adding files to the project.
2010-11-02 18:58:14 +01:00
Erik Faye-Lund
5bd6a515cf editor: clean up resource-header
Remove newlines to reduce noise from visual studio when updating
the resources.

Fix _APS_NEXT_RESOURCE_VALUE so 104 won't be generated, it already
exist.
2010-11-02 18:58:13 +01:00
Erik Faye-Lund
f2c12d1351 editor: do not use MFC header
afxres.h is MFC-ism, and is not included in Visual Studio Express 2008.
To avoid confusing the resource editor in other visual studio versions,
let's implement a minimal version ourselves.
2010-09-05 15:37:54 +02:00
Erik Faye-Lund
126fbe1c33 editor: prevent crash on early disconnection
With some really bad luck, it was possible to crash inside
std::string::resize() if the connection was disconnected
right after sending the GET_TRACK command.
2010-09-05 00:07:25 +02:00
Erik Faye-Lund
1d4e1bb795 gcc: fix compilation warnings 2010-09-04 14:32:24 +02:00
Erik Faye-Lund
68ae5f69a6 editor: style-nit 2010-08-29 23:43:10 +02:00
Erik Faye-Lund
6693c3f8f4 protocol: use network byte-order
The network code assumes that the client and server have the
same endianess. This isn't always the case, so let's change
it all to network byte-order.

This change is not backwards compatible, so old clients and
new editors (or vica verca) will not work together any more.
2010-08-29 23:43:10 +02:00
Erik Faye-Lund
163194e338 editor: increase warning level and fix warnings
While we're at it, let's fix-up some code-style errors.
2010-08-29 23:43:08 +02:00
Erik Faye-Lund
197f80010c editor: refactor command-processing 2010-07-26 13:02:19 +02:00
Erik Faye-Lund
e640a4ab6a editor: explicit C-declaration around sync/data.h
Trade an explicit extern "C" declaration for three
defined(__cplusplus) wrapped ones.
2010-07-06 23:03:37 +02:00
Erik Faye-Lund
47d8e9de6c editor: fix aborting save on exit 2010-07-05 19:07:02 +02:00
Erik Faye-Lund
1e94cd9975 Merge branch 'work/no-console' 2010-06-18 20:16:12 +02:00
Erik Faye-Lund
d68a38f451 editor: clean up error reporting 2010-06-18 20:09:01 +02:00
Erik Faye-Lund
12328ce6b8 editor: do not create a console window 2010-06-18 20:09:00 +02:00
Erik Faye-Lund
6ff7583935 editor: remove dead code
In 0e0b99e5, I accidentally committed some dead code. Remove it.
2010-06-18 20:08:24 +02:00
Erik Faye-Lund
31ec5064b2 editor: allow reordering tracks by dragging mouse
Previously the only way of reordering tracks were with an
obscure keyboard short-cut. Most users would expect to be
able to do this with the mouse, so we'll allow that.
2010-06-18 16:29:11 +02:00
Erik Faye-Lund
b5edcbe55d editor: make autoscrolling optional 2010-06-18 16:29:09 +02:00
Erik Faye-Lund
6d9b923461 editor: use beam-cursor in track view 2010-06-18 16:29:08 +02:00
Erik Faye-Lund
539522eb1e Merge branch 'work/update-scrollbars' 2010-04-26 21:15:12 +02:00
Erik Faye-Lund
128457b5fa Merge branch 'work/status-interp-mode' 2010-04-25 14:32:05 +02:00
Erik Faye-Lund
d1403d63f2 editor: refactor status-bar creation 2010-04-25 14:31:35 +02:00
Erik Faye-Lund
51d1e706bf editor: show interpolation mode
Show the interpolation mode in the status-bar. This is a little bit
more useful for people who are new to GNU Rocket than just using some
undocumented color-code in the track.
2010-04-25 14:31:23 +02:00
Erik Faye-Lund
cda73d0960 editor: update scrollbars after loading 2010-04-20 21:40:18 +02:00
Erik Faye-Lund
87e5f0d421 editor: reduce hinstance getting
Store hInstance in a global variable instead of getting it over and
over again.
2010-04-20 20:01:55 +02:00
Erik Faye-Lund
9f6eeb0b5d editor: portability fixes
This is mostly just nit-pickery that allows most of the editor to
be compiled with MinGW. The nasty COM-stuff for the XML-loader in
syncdocument.cpp is still not compiling, though. There's also some
missing resource definitions, it seems.
2010-03-24 21:41:35 +01:00
Erik Faye-Lund
f22e5c3bcd editor: support unicode filenames 2010-03-24 20:08:44 +01:00
Erik Faye-Lund
f5c2fc032e editor: remove traces of stdafx 2010-03-24 19:01:00 +01:00
Erik Faye-Lund
892e1e1a97 editor: max char width constness 2010-03-24 18:21:16 +01:00
Erik Faye-Lund
06c75438cf editor: get rid of some TCHARism
We dont need unicode everywhere. TCHARism is just noise.
2010-03-24 18:21:09 +01:00
Erik Faye-Lund
874c5b8ede rename LICENSE.TXT to COPYING 2010-03-19 17:41:37 +01:00
Erik Faye-Lund
42fc8cb3d7 remove unused ini-file 2010-03-19 17:41:37 +01:00