How to set a mobile view at the start of the project?

bambinou

Client
Регистрация
22.08.2011
Сообщения
442
Благодарностей
21
Баллы
18
Hello
A.
I would like to set a mobile view at the start of the project but cannot find out how as this is not great:
instance.SetWindowSize (411, 731);

Is there a better way to tell the browser that this instance is from an android xl (example).
Thank you.
 

ibred

Client
Регистрация
04.04.2015
Сообщения
3 835
Благодарностей
3 552
Баллы
113

bambinou

Client
Регистрация
22.08.2011
Сообщения
442
Благодарностей
21
Баллы
18
Thanks I tried that but it failed. Using this method do not help with the screen size and also the detection of a specific mobile view ie: Ipad Pro view, Ios view and so on.
I was hoping for a tool like the Chrome dev tool where you can set a view and work on that specific view.
 

ibred

Client
Регистрация
04.04.2015
Сообщения
3 835
Благодарностей
3 552
Баллы
113
After the profile is generated. The screen size of the device will be in the variables {-Profile.ScreenSizeWidth-} and {-Profile.ScreenSizeHeight-}. Therefore, in order to set the window size in accordance with the device, you need to execute this C # code:
C#:
instance.SetWindowSize(project.Profile.ScreenSizeWidth, project.Profile.ScreenSizeHeight);
Do not forget to turn on the screen emulation option.

 

bambinou

Client
Регистрация
22.08.2011
Сообщения
442
Благодарностей
21
Баллы
18
I see, excellent trick, thank you so much. Is there a way to trigger a specific device like Ipad pro? So your target believes you have an iPad?
 

ibred

Client
Регистрация
04.04.2015
Сообщения
3 835
Благодарностей
3 552
Баллы
113

VladZen

Administrator
Команда форума
Регистрация
05.11.2014
Сообщения
22 453
Благодарностей
5 913
Баллы
113

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)