Search:

Type: Posts; User: sethjackson

Page 1 of 4 1 2 3 4

Search: Search took 0.01 seconds.

  1. Replies
    6
    Views
    4,882

    EDIT: Point taken. Thanks. I'm gonna refactor...

    EDIT:

    Point taken. Thanks.
    I'm gonna refactor this.
    Thanks for the help everyone. :)
  2. Replies
    6
    Views
    4,882

    Aha! Thanks laserlight. I've got it working now....

    Aha! Thanks laserlight. I've got it working now.
    Yeah I don't know why I was getting unresolved symbols.
    I probably did something dumb with my build.

    Thanks for the help. :)
  3. Replies
    6
    Views
    4,882

    Mind explaining why? Because that doesn't make...

    Mind explaining why?
    Because that doesn't make sense to me and when I tried it it didn't work.
    Thanks for the reply though.
  4. Replies
    6
    Views
    4,882

    C++ method lookup

    Umm so I ran into this weird problem today.
    It's probably my own ignorance but I wanted to know why this happens
    and if it's supposed to.

    Say I have this code:
    (Using MinGW/GCC 4.5 compiler on...
  5. LOL I'm an idiot. Thanks.

    LOL I'm an idiot. Thanks.
  6. Changing the window frame styles causes the window to disappear

    Ok so I have this function that will let you switch whether a window can be resized or not.



    void Window::SetResizable(bool resizable)
    {
    DWORD dwStyles;

    if (resizable)
    ...
  7. Replies
    11
    Views
    3,800

    Figured it out. I was wrapping the platform...

    Figured it out.

    I was wrapping the platform specific data types in #ifdef PLATFORM_FOO(s)/#endif pairs in my library.

    I defined them upon building the library but not the app.
    Once I defined...
  8. Replies
    11
    Views
    3,800

    Ugh. This just keeps getting weirder. So I...

    Ugh. This just keeps getting weirder.
    So I decided to statically link my code into the app to test.
    No go. Same old crash.

    However, stepping through the calls after the crash in GDB will cause...
  9. Replies
    11
    Views
    3,800

    Hmm on a hunch I compiled the code directly into...

    Hmm on a hunch I compiled the code directly into my app instead of using a DLL for the Widget/Window/Button/Application classes.
    Now everything works fine.

    However, this isn't a solution.
    I want...
  10. Replies
    11
    Views
    3,800

    Yes. The button isn't created with the...

    Yes.




    The button isn't created with the WS_OVERLAPPED style...
    It is a child of the main window...
  11. Replies
    11
    Views
    3,800

    base class for all UI elements is Widget. Window...

    base class for all UI elements is Widget. Window represents a top level window, not a button or text entry, those are derived directly from Widget.
    So top level windows need the WS_OVERLAPPEDWINDOW...
  12. Replies
    11
    Views
    3,800

    While I *could* use...

    While I *could* use MFC/Gtk+/Qt/wxWidgets/WinForms/whatever else, I choose not to.
    Anyone gather any ideas from the backtrace??
  13. Replies
    11
    Views
    3,800

    The class "MyClassName" is only registered once,...

    The class "MyClassName" is only registered once, the first time the Widget constructor is called. It's lazy initialized (actually this technique isn't thread-safe but I'm not concerned about that...
  14. Replies
    11
    Views
    3,800

    C++ destructors/window subclassing

    I'm trying to make a simple C++ wrapper around the Windows UI library but I'm getting some weird crashes that I can't seem to debug.

    I have a base class Widget that does all the...
  15. Replies
    2
    Views
    991

    You have to tell the compiler that you are...

    You have to tell the compiler that you are compiling a Windows GUI program.
    Otherwise it thinks you are trying to compile a console program and you will get the above error.

    Add this to your...
  16. Also, why are you taking a string by const value?...

    Also, why are you taking a string by const value? Do you really want a *copy* of it?
    Since you are passing a const value you can't modify the value anyway. Might as well pass by ref and save some...
  17. Replies
    7
    Views
    1,390

    I use something along the lines of the...

    I use something along the lines of the .NET/Gtk+/Qt documentation style...

    Like so:



    /**
    * Removes the specified item from the list if it exists.
    *
    * This function requires the value...
  18. Replies
    6
    Views
    1,834

    We already have those (well unless your compiler...

    We already have those (well unless your compiler doesn't support C99).

    int8_t
    int16_t

    :)
  19. Well it uses XML for one, and it is more akin to...

    Well it uses XML for one, and it is more akin to Makefiles than other systems IMO....
    I can't tell you if it is "better" than other systems, but I do know that it is simple, and easy to use (for me...
  20. Replies
    6
    Views
    1,306

    Not quite.... You would have to change Run()...

    Not quite....

    You would have to change Run() everytime you want to do something different....

    Something like this is what I was saying.....



    virtual void Run() = 0;
  21. Bakefile!!! http://www.bakefile.org/ I love...

    Bakefile!!!

    http://www.bakefile.org/

    I love it. :D
  22. Replies
    6
    Views
    1,306

    Check this out. DWORD WINAPI...

    Check this out.



    DWORD WINAPI ThreadProxy(void* arg)
    {
    Thread* thread = static_cast<Thread* >(arg);

    thread->Run();
  23. Replies
    3
    Views
    8,291

    Why didn't I think of that, must have not read...

    Why didn't I think of that, must have not read the man page thoroughly....

    Thanks CornedBee. :)
  24. Replies
    3
    Views
    8,291

    File descriptor file position

    How do I get the current file position from a file descriptor?

    I don't see anything like ftell(), for file descriptors.....

    Thanks!
  25. Replies
    17
    Views
    4,088

    Heh yep. Thanks mats!!

    Heh yep. Thanks mats!!
Results 1 to 25 of 97
Page 1 of 4 1 2 3 4