Not logged inOpenClonk Forum
Up Topic Mac Dev Mode

This board is threaded (i.e. has a tree structure). Please use the Reply button of the specific post you are referring to, not just any random button. If you want to reply to the topic in general, use the Post button near the top and bottom of the page.

Post Reply
In Response to Günther
Comments on the first half:
- I don't like those "id" changes. Imho, .cpp files shouldn't be compiled as if they were Objective C++, because that's just not what they are.
- I'd suggest squashing "Startup code USE_COCOA aware" and "Reorganize main code by putting the components of the application's lifecycle into a class named C4Main" because the latter deletes questionable code the former introduces. Though maybe some stuff from C4WinMain.cpp should just be put into C4Application, and the remaining trivial main function just duplicated.
- I don't like "Mac: Shuffle drawing code around to make it easier to call it inside a NSView drawRect: method". It seems to disable automatic drawing in some circumstances and define an interface to respond to expose events. That can and should be done without ifdefs. The other platforms just need a stub "StdWindow::isVisible() { return true; }", and a standard StdWindow::Redraw() method. Or does the cocoa code try to post expose events which are later responded to? That can be done with a standard StdWindow::MarkForUpdate() (or similar) method, which just calls Redraw() normally and does the roundabout thing for cocoa.
- A lot of the copyright headers are bogus. We either need to all agree to just put a "Copyright (c) 1998-2010 various contributers", or you need to carry over the copyright messages along with code you move, and put just your name on new files written from scratch.
- The commit adding StdAppCommon.cpp needs to add the file to at least CMakeLists.txt, and ideally also to Makefile.am.
- If you're not using StdSDL*, excluding it from the build is more elegant than putting in #ifdefs.
- What's the point of making lots of functions public in "Mac Console: Output + Save Panels"?
- "Mac: Implement CStdGLCtx for Cocoa" has inconsistent indentation. Also, we should probably look some more for redundancy in the four implementations, but that can wait.
- The #ifdef mess in the developer mode implementation is ugly, but I don't have any bright ideas how to improve it.
- There should be no source code in the xcode/ directory. That's only for build system stuff.
- The material preview in the toolbox should probably be done with OpenGL for all window systems, but that can also wait.
- Ah, "Add StdAppCommon to CMake" and "Include C4Include in StdAppCommon.cpp since that seems to be required by VS" should be squashed into the above-mentioned "Add StdMacWindow.mm and move some functions defined in StdWindow.h to StdAppCommon.cpp".
- "Mac: Code that should do something but doesn't" is a terrible commit message :-p

Next half later.

Powered by mwForum 2.29.7 © 1999-2015 Markus Wichitill