Welcome, Guest. Please login or register. Did you miss your activation email?

Show Posts

This section allows you to view all posts made by this member. Note that you can only see posts made in areas you currently have access to.


Messages - skaught

Pages: [1]
1
Ok, I see what you were asking now.

I tried out your code, as it currently is, the cursor shows over the window.

However, if I change the window size to be 1920x1200, my current screen resolution. It actually kind of acts like it went to fullscreen mode instead of windowed without decorations.

Also the mouse now dissapears when I move it over the window.

The mouse also dissapears in Fullscreen.

2
Yes, I call it after creating the window.

Sorry, here's an excerpt from my code, I've pulled some stuff out.

I guess I should note that in this particular case _owner->getX() and _owner->getY() return 1, so the window size is the desktop size, 1920x1200.

void WindowThread::operator ()()
{
        sf::ContextSettings settings;
        settings.depthBits = 16;
        settings.stencilBits = 8;
        sf::Window window(sf::VideoMode(width, height, desktop.bitsPerPixel), _owner->getName(),sf::Style::None,settings);
        window.setMouseCursorVisible(true);
        int x = static_cast<int>(desktop.width * _owner->getX());
        int y = static_cast<int>(desktop.height * _owner->getY());
        window.setPosition(sf::Vector2i(x, y));
        window.setActive(false);
        _owner->resize(width, height);
        utility::refct_ptr<RenderThread> renderThread(new RenderThread(_owner, &window));
        _owner->setRenderThread(renderThread);
        renderThread->run();
        sf::Event event;
        sf::Keyboard::Key lastKey = sf::Keyboard::Unknown;
        utility::Rect<int> mouseInfo(0,0,(int)width,(int)height);
        while(wait(1000) != EWAIT_TERMINATE) {
                //handle events
        }
}

void RenderThread::operator ()()
{      
        while(wait(10000000) != EWAIT_TERMINATE) {
                _window->setActive(true);
                while(!_eventQueue.empty()) {
                        _eventQueue.front()();
                        _eventQueue.pop();
                }
                _owner->draw();
                _window->display();
        }
}
 

3
Hello,

I recently started using SFML 2.0 for our software's windowing, unfortunately I've run into a bit of an issue.

When setting the window style to Fullscreen or None, the mouse cursor dissapears when I move the mouse over the window. I've tried calling window.setMouseCursorVisible(true); but that has no effect.

Running Windows 7 64 bit, aero enabled.
ATI Radeon HD5800 with latest drivers.
It's a dev machine and has 3 monitors.


Pages: [1]