How to create a new window and have the focus back to the main window?

I’m trying to create a new window and get focus back (keyboard events) to the main window.
Right now I can’t do it on macOs, using this code. maybe I’m missing something.

		ofGLFWWindowSettings settings;
		settings.windowMode = OF_WINDOW;
		auto mainWindow = ofGetCurrentWindow();
		settings.shareContextWith = mainWindow;
		for (int a=0; a<10; a++) {
			settings.setSize( 200, 200 );
			int spacing = 25;
			settings.setPosition( { a * spacing + 140, a * spacing + 140 });
			ofAddListener(allWindows.back()->events().draw, this, &ofApp::drawSecondWindow);

I think you need to use this call:

glfwFocusWindow with the glfw window pointer.

makeCurrent is just for OF’s internal window management ( ie: this is the window I want info from when using getWidth / getHeight etc ).