[go: up one dir, main page]

CN106020649B - Picture rotation control method and device - Google Patents

Picture rotation control method and device Download PDF

Info

Publication number
CN106020649B
CN106020649B CN201610371869.6A CN201610371869A CN106020649B CN 106020649 B CN106020649 B CN 106020649B CN 201610371869 A CN201610371869 A CN 201610371869A CN 106020649 B CN106020649 B CN 106020649B
Authority
CN
China
Prior art keywords
screen
rotation function
state
electronic equipment
picture
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201610371869.6A
Other languages
Chinese (zh)
Other versions
CN106020649A (en
Inventor
王辰汐
赵盼盼
乔忠良
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Xiaomi Mobile Software Co Ltd
Original Assignee
Beijing Xiaomi Mobile Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Xiaomi Mobile Software Co Ltd filed Critical Beijing Xiaomi Mobile Software Co Ltd
Priority to CN201610371869.6A priority Critical patent/CN106020649B/en
Publication of CN106020649A publication Critical patent/CN106020649A/en
Application granted granted Critical
Publication of CN106020649B publication Critical patent/CN106020649B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0484Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range
    • G06F3/04845Interaction techniques based on graphical user interfaces [GUI] for the control of specific functions or operations, e.g. selecting or manipulating an object, an image or a displayed text element, setting a parameter value or selecting a range for image manipulation, e.g. dragging, rotation, expansion or change of colour
    • GPHYSICS
    • G06COMPUTING OR CALCULATING; COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F3/00Input arrangements for transferring data to be processed into a form capable of being handled by the computer; Output arrangements for transferring data from processing unit to output unit, e.g. interface arrangements
    • G06F3/01Input arrangements or combined input and output arrangements for interaction between user and computer
    • G06F3/048Interaction techniques based on graphical user interfaces [GUI]
    • G06F3/0487Interaction techniques based on graphical user interfaces [GUI] using specific features provided by the input device, e.g. functions controlled by the rotation of a mouse with dual sensing arrangements, or of the nature of the input device, e.g. tap gestures based on pressure sensed by a digitiser

Landscapes

  • Engineering & Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • User Interface Of Digital Computer (AREA)

Abstract

本公开是关于一种图片旋转控制方法和装置,属于计算机技术领域。所述图片旋转控制方法包括:在用于显示图片的图片应用程序在前台运行过程中,获取所述电子设备的旋转次数;当所述旋转次数达到预定次数阈值时,根据所述电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,所述状态为锁定或解锁;在所述状态修改控件被触发时,修改所述屏幕自动旋转功能的状态;解决了相关技术中切换屏幕自动旋转功能的状态操作繁琐的问题,简化了切换屏幕自动旋转功能的状态的操作。

The disclosure relates to a picture rotation control method and device, and belongs to the technical field of computers. The picture rotation control method includes: acquiring the rotation times of the electronic device when the picture application program for displaying pictures is running in the foreground; The current state of the automatic rotation function displays the state modification control, and the state is locked or unlocked; when the state modification control is triggered, the state of the automatic rotation function of the screen is modified; it solves the problem of switching the automatic rotation function of the screen in the related art The problem of cumbersome state operations has been solved, and the operation of switching the state of the screen auto-rotation function has been simplified.

Description

图片旋转控制方法和装置Picture rotation control method and device

技术领域technical field

本公开涉及计算机技术领域,特别涉及一种图片旋转控制方法和装置。The present disclosure relates to the field of computer technology, and in particular to a picture rotation control method and device.

背景技术Background technique

电子设备屏幕的横向尺寸和竖向尺寸不同,在一些应用场景中,需要电子设备将需要展示的内容进行横屏展示,在另一些应用场景中,需要电子设备将需要展示的内容进行竖屏展示。因此,为了使电子设备能够自动适应场景调整屏幕的显示方向,用户可以设置电子设备屏幕显示方向的自动调整功能。The horizontal size and vertical size of the electronic device screen are different. In some application scenarios, the electronic device is required to display the content to be displayed on the horizontal screen. In other application scenarios, the electronic device is required to display the content to be displayed on the vertical screen. . Therefore, in order to enable the electronic device to automatically adapt to the scene and adjust the display direction of the screen, the user can set the automatic adjustment function of the screen display direction of the electronic device.

当用户需要开启或关闭电子设备的屏幕自动旋转功能时,需要切换至包含用于开启和关闭屏幕自动旋转功能的控件的页面,再通过触发对应控件来切换屏幕自动旋转功能的状态,这种切换屏幕自动旋转功能状态的方式操作繁琐。When the user needs to turn on or off the automatic screen rotation function of the electronic device, he needs to switch to the page containing the controls for turning on and off the automatic screen rotation function, and then switch the state of the automatic screen rotation function by triggering the corresponding control. The way the screen automatically rotates the function state is cumbersome to operate.

发明内容Contents of the invention

本公开实施例提供了一种图片旋转控制方法和装置。所述技术方案如下:根据本公开实施例的第一方面,提供了一种图片旋转控制方法,所述方法包括:在用于显示图片的图片应用程序在前台运行过程中,获取所述电子设备的旋转次数;当所述旋转次数达到预定次数阈值时,根据所述电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,所述状态为锁定或解锁;在所述状态修改控件被触发时,修改所述屏幕自动旋转功能的状态;通过检测电子设备的旋转次数,当检测到旋转次数达到预定次数阈值,认为电子设备当前的屏幕自动旋转功能的状态不符合用户需求,此时向用户提供用户修改屏幕自动旋转功能的状态的控件,解决了相关技术中切换屏幕自动旋转功能的状态操作繁琐的问题,简化了用户切换切换屏幕自动旋转功能的状态操作。Embodiments of the present disclosure provide a picture rotation control method and device. The technical solution is as follows: According to the first aspect of the embodiments of the present disclosure, there is provided a picture rotation control method, the method includes: when the picture application program for displaying pictures is running in the foreground, acquiring the electronic device number of rotations; when the number of rotations reaches a predetermined threshold, a state modification control is displayed according to the current state of the screen auto-rotation function of the electronic device, and the state is locked or unlocked; when the state modification control is triggered , modify the state of the automatic screen rotation function; by detecting the number of rotations of the electronic device, when it is detected that the number of rotations reaches the predetermined number threshold, it is considered that the current state of the automatic screen rotation function of the electronic device does not meet the user's needs, and the user is notified at this time The user is provided with a control for modifying the state of the automatic screen rotation function, which solves the problem of cumbersome operation of switching the state of the automatic screen rotation function in the related art, and simplifies the operation of switching the state of the automatic screen rotation function for the user.

可选的,所述根据所述电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,包括:当所述电子设备的屏幕自动旋转功能当前的状态为锁定时,显示用于引导解锁所述屏幕自动旋转功能的第一状态修改控件;当所述电子设备的屏幕自动旋转功能当前的状态为解锁时,显示用于引导锁定所述屏幕自动旋转功能的第二状态修改控件。Optionally, the displaying the state modification control according to the current state of the automatic screen rotation function of the electronic device includes: when the current state of the automatic screen rotation function of the electronic device is locked, displaying the The first state modification control of the automatic screen rotation function; when the current state of the automatic screen rotation function of the electronic device is unlocked, the second state modification control for guiding and locking the automatic screen rotation function is displayed.

可选的,所述在所述状态修改控件被触发时,修改所述屏幕自动旋转功能的状态,包括:当所述状态修改控件为所述第一状态修改控件,且所述第一状态修改控件被触发时,解锁所述电子设备的屏幕自动旋转功能;当所述状态修改控件为所述第二状态修改控件,且所述第二状态修改控件被触发时,锁定所述电子设备的屏幕自动旋转功能。Optionally, when the state modification control is triggered, modifying the state of the automatic screen rotation function includes: when the state modification control is the first state modification control, and the first state modification When the control is triggered, the automatic screen rotation function of the electronic device is unlocked; when the state modification control is the second state modification control, and the second state modification control is triggered, the screen of the electronic device is locked Auto-rotate feature.

可选的,所述方法还包括:在所述图片应用程序在前台运行过程中,获取所述图片应用程序被开启前所述电子设备最后的屏幕显示方向;获取所述电子设备在所述图片应用程序在前台运行过程中的重力感应方向;当所述屏幕显示方向与所述重力感应方向之间的夹角首次达到第一角度阈值且所述电子设备的屏幕自动旋转功能为解锁时,锁定所述电子设备的屏幕自动旋转功能;通过将图片应用程序被开启前电子设备最后的屏幕显示方向作为贴合用户浏览图片需求的参考方向,当重力感应方向与该参考方向的夹角首次达到第一角度阈值时锁定屏幕自动旋转功能,锁定了屏幕显示方向,使得屏幕的显示方向贴合用户查看需求。Optionally, the method further includes: while the picture application program is running in the foreground, acquiring the last screen display direction of the electronic device before the picture application program is started; Gravity sensing direction when the application is running in the foreground; when the angle between the screen display direction and the gravity sensing direction reaches the first angle threshold for the first time and the screen auto-rotation function of the electronic device is unlocked, lock The automatic screen rotation function of the electronic device; by using the last screen display direction of the electronic device before the picture application program is opened as the reference direction that meets the needs of the user to browse pictures, when the angle between the gravity sensing direction and the reference direction reaches the first When an angle threshold is reached, the automatic rotation function of the screen is locked, and the display direction of the screen is locked, so that the display direction of the screen fits the user's viewing needs.

可选的,所述方法还包括:在获取所述重力感应方向后,在所述重力感应方向与所述屏幕显示方向之间的夹角小于第二角度阈值且所述电子设备的屏幕自动旋转功能为锁定时,解锁所述电子设备的屏幕自动旋转功能;实现了当电子设备的屏幕自动旋转功能被锁定且用户处于非侧卧姿态浏览图片的情况下,自动解锁屏幕自动旋转功能,使得习惯锁定系统的屏幕自动旋转功能的用户在浏览图片时,能够通过旋转电子设备来控制照片的显示方向。Optionally, the method further includes: after acquiring the gravity sensing direction, the angle between the gravity sensing direction and the screen display direction is smaller than a second angle threshold and the screen of the electronic device automatically rotates When the function is locked, the automatic screen rotation function of the electronic device is unlocked; when the automatic screen rotation function of the electronic device is locked and the user is in a non-side-lying posture to browse pictures, the automatic screen rotation function is automatically unlocked, making the user accustomed to Users who lock the system's automatic screen rotation function can control the display orientation of photos by rotating the electronic device when viewing photos.

可选的,当未获取到所述图片应用程序被开启前电子设备最后的屏幕显示方向时,控制所述电子设备的屏幕自动旋转功能处于解锁状态。Optionally, when the last screen display orientation of the electronic device before the picture application is started is not obtained, the automatic screen rotation function of the electronic device is controlled to be in an unlocked state.

可选的,所述方法还包括:在解锁所述电子设备的屏幕自动旋转功能后,在所述图片应用程序所打开的同一张图片在屏幕上持续显示的过程中,获取屏幕显示方向的变化次数;当所述变化次数达到预定次数阈值时,显示与所述图片相关的图片旋转控件;根据被触发的所述图片旋转控件,控制所述图片进行旋转;使得用户能够通过对图片进行旋转。Optionally, the method further includes: after unlocking the automatic screen rotation function of the electronic device, during the continuous display of the same picture opened by the picture application program on the screen, acquiring the change of the screen display direction number of times; when the number of changes reaches a predetermined number of thresholds, display the picture rotation control related to the picture; control the picture to rotate according to the triggered picture rotation control; enable the user to rotate the picture.

可选的,所述方法还包括:当所述图片应用程序退出前台运行时,将所述电子设备的屏幕自动旋转功能的开启状态恢复至所述图片应用程序在前台运行前的状态。Optionally, the method further includes: when the picture application exits from running in the foreground, restoring the enabled state of the automatic screen rotation function of the electronic device to the state before the picture application runs in the foreground.

根据本公开实施例的第二方面,提供了一种图片旋转控制装置,所述装置包括:第一获取模块,被配置为在用于显示图片的图片应用程序在前台运行过程中,获取所述电子设备的旋转次数;显示模块,被配置当所述旋转次数达到预定次数阈值时,根据所述电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,所述状态为锁定或解锁;修改模块,被配置在所述状态修改控件被触发时,修改所述屏幕自动旋转功能的状态。According to a second aspect of the embodiments of the present disclosure, there is provided a picture rotation control device, the device comprising: a first acquisition module configured to acquire the The number of rotations of the electronic device; the display module is configured to display a state modification control according to the current state of the screen automatic rotation function of the electronic device when the number of rotations reaches a predetermined threshold value, and the state is locked or unlocked; modify A module configured to modify the state of the screen auto-rotation function when the state modification control is triggered.

可选的,所述显示模块包括:第一显示子模块,被配置为所述电子设备的屏幕自动旋转功能当前的状态为锁定时,显示用于引导解锁所述屏幕自动旋转功能的第一状态修改控件;第二显示子模块,被配置为当所述电子设备的屏幕自动旋转功能当前的状态为解锁时,显示用于引导锁定所述屏幕自动旋转功能的第二状态修改控件。Optionally, the display module includes: a first display submodule, configured to display the first status for guiding unlocking of the screen auto-rotation function when the current state of the screen auto-rotation function of the electronic device is locked Modification control; the second display submodule is configured to display a second state modification control for guiding and locking the automatic screen rotation function when the current state of the automatic screen rotation function of the electronic device is unlocked.

可选的,所述修改模块包括:解锁子模块,被配置为当所述状态修改控件为所述第一状态修改控件,且所述第一状态修改控件被触发时,解锁所述电子设备的屏幕自动旋转功能;锁定子模块,被配置为当所述状态修改控件为所述第二状态修改控件,且所述第二状态修改控件被触发时,锁定所述电子设备的屏幕自动旋转功能。Optionally, the modifying module includes: an unlocking submodule configured to unlock the electronic device when the state modifying control is the first state modifying control and the first state modifying control is triggered. Automatic screen rotation function; a locking submodule configured to lock the automatic screen rotation function of the electronic device when the state modification control is the second state modification control and the second state modification control is triggered.

可选的,所述装置还包括:第二获取模块,被配置为在所述图片应用程序在前台运行过程中,获取所述图片应用程序被开启前所述电子设备最后的屏幕显示方向;第三获取模块,被配置为获取所述电子设备在所述图片应用程序在前台运行过程中的重力感应方向;锁定模块,被配置为当所述屏幕显示方向与所述重力感应方向之间的夹角首次达到第一角度阈值且所述电子设备的屏幕自动旋转功能为解锁时,锁定所述电子设备的屏幕自动旋转功能。Optionally, the device further includes: a second acquiring module, configured to acquire the last screen display direction of the electronic device before the picture application is started while the picture application is running in the foreground; 3. An acquisition module, configured to acquire the gravity sensing direction of the electronic device when the picture application program is running in the foreground; a locking module, configured to obtain the gravity sensing direction between the screen display direction and the gravity sensing direction When the angle reaches the first angle threshold for the first time and the automatic screen rotation function of the electronic device is unlocked, the automatic screen rotation function of the electronic device is locked.

可选的,所述装置还包括:解锁模块,被配置为在获取所述重力感应方向后,在所述重力感应方向与所述屏幕显示方向之间的夹角小于第二角度阈值且所述电子设备的屏幕自动旋转功能为锁定时,解锁所述电子设备的屏幕自动旋转功能。Optionally, the device further includes: an unlocking module configured to, after acquiring the gravity sensing direction, an included angle between the gravity sensing direction and the screen display direction is smaller than a second angle threshold and the When the automatic screen rotation function of the electronic device is locked, the automatic screen rotation function of the electronic device is unlocked.

可选的,所述装置还包括:控制模块,被配置为当未获取到所述图片应用程序被开启前电子设备最后的屏幕显示方向时,控制所述电子设备的屏幕自动旋转功能处于解锁状态。Optionally, the device further includes: a control module, configured to control the automatic screen rotation function of the electronic device to be in an unlocked state when the last screen display orientation of the electronic device before the picture application is started is not obtained. .

可选的,所述装置还包括:恢复模块,被配置为当所述图片应用程序退出前台运行时,将所述电子设备的屏幕自动旋转功能的开启状态恢复至所述图片应用程序在前台运行前的状态。Optionally, the device further includes: a recovery module, configured to restore the automatic screen rotation function of the electronic device to the state where the picture application program is running in the foreground when the picture application program exits the foreground operation previous state.

根据本公开实施例的第三方面,提供了一种图片旋转控制装置,包括:处理器;用于存储所述处理器的可执行指令的存储器;其中,所述处理器被配置为:在用于显示图片的图片应用程序在前台运行过程中,获取所述电子设备的旋转次数;当所述旋转次数达到预定次数阈值时,根据所述电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,所述状态为锁定或解锁;在所述状态修改控件被触发时,修改所述屏幕自动旋转功能的状态。According to a third aspect of the embodiments of the present disclosure, there is provided a picture rotation control device, including: a processor; a memory for storing executable instructions of the processor; wherein, the processor is configured to: Acquire the number of rotations of the electronic device during the running of the picture application program for displaying pictures; when the number of rotations reaches a predetermined threshold, the display state is modified according to the current state of the automatic screen rotation function of the electronic device Control, the state is locked or unlocked; when the state modification control is triggered, modify the state of the automatic screen rotation function.

附图说明Description of drawings

此处的附图被并入说明书中并构成本说明书的一部分,示出了符合本公开的实施例,并与说明书一起用于解释本公开的原理。The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description serve to explain the principles of the disclosure.

图1是根据一示例性实施例示出的一种图片旋转控制方法的流程图;Fig. 1 is a flowchart of a picture rotation control method shown according to an exemplary embodiment;

图2A是根据另一示例性实施例示出的一种图片旋转控制方法的流程图;Fig. 2A is a flowchart of a picture rotation control method according to another exemplary embodiment;

图2B是根据一示例性实施例示出的一种电子设备旋转示意图;Fig. 2B is a schematic diagram showing the rotation of an electronic device according to an exemplary embodiment;

图2C是根据一示例性实施例示出的一种实现屏幕自动旋转功能的锁定的方法流程图;Fig. 2C is a flow chart showing a method for locking the automatic screen rotation function according to an exemplary embodiment;

图2D是根据一示例性实施例示出的一种图片应用程序被开启前屏幕显示方向的示意图;Fig. 2D is a schematic diagram of a screen display direction before a picture application is started according to an exemplary embodiment;

图2E是根据一示例性实施例示出的一种锁定屏幕显示方向的示意图;Fig. 2E is a schematic diagram showing a display direction of a lock screen according to an exemplary embodiment;

图2F是根据一示例性实施例示出的一种解锁屏幕自动旋转功能方法的流程图;Fig. 2F is a flowchart of a method for unlocking the automatic screen rotation function according to an exemplary embodiment;

图2G是根据一示例性实施例示出的一种屏幕自动旋转功能解锁的示意图;Fig. 2G is a schematic diagram of unlocking the automatic screen rotation function according to an exemplary embodiment;

图2H是根据一示例性实施例示出的一种向用户提供用于控制照片旋转的控件的方法流程图;Fig. 2H is a flow chart of a method for providing users with controls for controlling photo rotation according to an exemplary embodiment;

图2I是根据一示例性实施例示出的照片旋转示意图;Fig. 2I is a schematic diagram showing photo rotation according to an exemplary embodiment;

图3是根据一示例性实施例示出的一种图片旋转控制装置的框图;Fig. 3 is a block diagram of a picture rotation control device according to an exemplary embodiment;

图4是根据另一示例性实施例示出的一种图片旋转控制装置的框图;Fig. 4 is a block diagram of a picture rotation control device according to another exemplary embodiment;

图5是根据一示例性实施例示出的一种用于图片旋转控制的装置的框图。Fig. 5 is a block diagram of an apparatus for picture rotation control according to an exemplary embodiment.

具体实施方式Detailed ways

这里将详细地对示例性实施例进行说明,其示例表示在附图中。下面的描述涉及附图时,除非另有表示,不同附图中的相同数字表示相同或相似的要素。以下示例性实施例中所描述的实施方式并不代表与本公开相一致的所有实施方式。相反,它们仅是与如所附权利要求书中所详述的、本公开的一些方面相一致的装置和方法的例子。Reference will now be made in detail to the exemplary embodiments, examples of which are illustrated in the accompanying drawings. When the following description refers to the accompanying drawings, the same numerals in different drawings refer to the same or similar elements unless otherwise indicated. The implementations described in the following exemplary examples do not represent all implementations consistent with the present disclosure. Rather, they are merely examples of apparatuses and methods consistent with aspects of the present disclosure as recited in the appended claims.

图1是根据一示例性实施例示出的一种图片旋转控制方法的流程图,该图片旋转控制方法可以包括如下几个步骤。Fig. 1 is a flowchart showing a picture rotation control method according to an exemplary embodiment, and the picture rotation control method may include the following steps.

在步骤101中,在用于显示图片的图片应用程序在前台运行过程中,获取该电子设备的旋转次数。In step 101, the number of rotations of the electronic device is acquired when a picture application program for displaying pictures is running in the foreground.

在步骤102中,当旋转次数达到预定次数阈值时,根据该电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,上述状态为锁定或解锁。In step 102, when the number of rotations reaches a predetermined threshold, a state modification control is displayed according to the current state of the automatic screen rotation function of the electronic device, and the above state is locked or unlocked.

在步骤103中,在状态修改控件被触发时,修改屏幕自动旋转功能的状态。In step 103, when the state modification control is triggered, the state of the automatic screen rotation function is modified.

综上所述,本公开实施例中提供的图片旋转控制方法,检测电子设备的旋转次数,当检测到旋转次数达到预定次数阈值,认为电子设备当前的屏幕自动旋转功能的状态不符合用户需求,此时向用户提供用户修改屏幕自动旋转功能的状态的控件,解决了相关技术中切换屏幕自动旋转功能的状态操作繁琐的问题,简化了用户切换屏幕自动旋转功能的状态操作。To sum up, the picture rotation control method provided in the embodiment of the present disclosure detects the number of rotations of the electronic device, and when it is detected that the number of rotations reaches a predetermined threshold, it is considered that the current state of the automatic screen rotation function of the electronic device does not meet the user's needs. At this time, the user is provided with a control for modifying the state of the screen auto-rotation function, which solves the problem of cumbersome operation of switching the state of the screen auto-rotation function in the related art, and simplifies the user's operation of switching the state of the screen auto-rotation function.

图2A是根据另一示例性实施例示出的一种图片旋转控制方法的流程图,该图片旋转控制方法可以包括如下几个步骤。Fig. 2A is a flow chart showing a picture rotation control method according to another exemplary embodiment, and the picture rotation control method may include the following steps.

在步骤201中,在用于显示图片的图片应用程序在前台运行过程中,获取该电子设备的旋转次数。In step 201, the number of rotations of the electronic device is acquired when a picture application program for displaying pictures is running in the foreground.

这里所讲的用于显示图片的应用程序可以为图片查看器、浏览器等等。The application program used for displaying pictures mentioned here may be a picture viewer, a browser, and the like.

可选的,在图片应用程序在前台运行的过程中,实时获取电子设备的重力感应方向,根据获取到的重力感应方向确定电子设备的姿态。当检测到处于底部的边框发生变化时,记为该电子设备被旋转一次。举例来讲,图2B是根据一示例性实施例示出的一种电子设备旋转示意图,手机的初始姿态如图2B(1)所示,此时检测到电子设备的底端边框为处于底部的边框,当用户逆时针旋转电子设备如图2B(2)所示,此时检测到电子设备的左侧边框为处于底部的边框,此时检测到电子设备处于底部的边框发生了变化,认为该电子设备旋转了一次。Optionally, when the picture application program is running in the foreground, the gravity sensing direction of the electronic device is acquired in real time, and the attitude of the electronic device is determined according to the acquired gravity sensing direction. When it is detected that the frame at the bottom changes, it is recorded as that the electronic device is rotated once. For example, FIG. 2B is a schematic diagram showing the rotation of an electronic device according to an exemplary embodiment. The initial posture of the mobile phone is shown in FIG. 2B (1), and at this time it is detected that the bottom border of the electronic device is the bottom border , when the user rotates the electronic device counterclockwise as shown in Figure 2B (2), at this time it is detected that the left frame of the electronic device is the frame at the bottom, and it is detected that the frame at the bottom of the electronic device has changed, it is considered that the electronic device The device rotated once.

在步骤202中,当旋转次数达到预定次数阈值时,根据该电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件。In step 202, when the number of rotations reaches a predetermined threshold, a state modification control is displayed according to the current state of the automatic screen rotation function of the electronic device.

预定次数阈值通常由系统开发人员设定,可选的,将预定次数阈值设置为2。The predetermined times threshold is usually set by a system developer, and optionally, the predetermined times threshold is set to 2.

当电子设备的旋转次数达到预定阈值时,认为当前的屏幕自动旋转功能的状态可能不符合用户的需求,此时向用户提供用于修改屏幕自动旋转功能状态的状态修改控件。When the number of rotations of the electronic device reaches a predetermined threshold, it is considered that the current state of the automatic screen rotation function may not meet the needs of the user, and at this time, a state modification control for modifying the state of the automatic screen rotation function is provided to the user.

这里所讲的屏幕自动旋转功能是电子设备根据实时获取的重力感应方向控制电子设备的屏幕显示方向自动旋转的功能。屏幕自动旋转功能的状态包括锁定和解锁,当屏幕自动旋转功能为解锁时,电子设备根据实时获取的重力感应方向控制电子设备的屏幕显示方向自动旋转;当屏幕自动旋转功能为锁定时,电子设备的屏幕显示方向被锁定。The automatic screen rotation function mentioned here is a function for the electronic device to automatically rotate the screen display direction of the electronic device according to the gravity sensing direction acquired in real time. The status of the screen auto-rotation function includes locking and unlocking. When the screen auto-rotation function is unlocked, the electronic device controls the screen display direction of the electronic device to automatically rotate according to the gravity sensing direction acquired in real time; when the screen auto-rotation function is locked, the electronic device The screen display orientation is locked.

具体的,本步骤可以通过以下两种可能的实施方式实现。Specifically, this step can be implemented through the following two possible implementation manners.

在第一种可能的实施方式中,当电子设备的屏幕自动旋转功能当前的状态为锁定时,显示用于引导解锁屏幕自动旋转功能的第一状态修改控件。In a first possible implementation manner, when the current state of the automatic screen rotation function of the electronic device is locked, a first state modification control for guiding the unlocking of the automatic screen rotation function is displayed.

为了避免第一状态修改控件对屏幕显示内容的遮挡。可选的,当第一状态修改控件在显示屏中持续显示达到预设时长时,取消对该第一状态修改控件的显示。In order to avoid the occlusion of the content displayed on the screen by the modification control in the first state. Optionally, when the first state modification control is continuously displayed on the display screen for a preset duration, the display of the first state modification control is canceled.

在第二种可能的实施方式中,当电子设备的屏幕自动旋转功能当前的状态为解锁时,显示用于引导锁定所述屏幕自动旋转功能的第二状态修改控件。In a second possible implementation manner, when the current state of the automatic screen rotation function of the electronic device is unlocked, a second state modification control for guiding and locking the automatic screen rotation function is displayed.

为了避免第二状态修改控件对屏幕显示内容的遮挡。可选的,当第二状态修改控件在显示屏中持续显示达到预设时长时,取消对该第二状态修改控件的显示。In order to avoid the occlusion of the content displayed on the screen by the second state modification control. Optionally, when the second state modification control is continuously displayed on the display screen for a preset duration, the display of the second state modification control is canceled.

在步骤203中,在状态修改控件被触发时,修改屏幕自动旋转功能的状态。In step 203, when the state modification control is triggered, the state of the automatic screen rotation function is modified.

具体的,本步骤可以通过以下两种可能的实施方式实现。Specifically, this step can be implemented through the following two possible implementation manners.

在第一种可能的实施方式中,当状态修改控件为第一状态修改控件,且第一状态修改控件被触发时,解锁电子设备的屏幕自动旋转功能。In a first possible implementation manner, when the state modification control is a first state modification control, and the first state modification control is triggered, the automatic screen rotation function of the electronic device is unlocked.

在第二种可能的实施方式中,当状态修改控件为第二状态修改控件,且第二状态修改控件被触发时,锁定电子设备的屏幕自动旋转功能。In a second possible implementation manner, when the state modification control is a second state modification control, and the second state modification control is triggered, the automatic screen rotation function of the electronic device is locked.

综上所述,本公开实施例中提供的图片旋转控制方法,检测电子设备的旋转次数,当检测到旋转次数达到预定次数阈值,认为电子设备当前的屏幕自动旋转功能的状态不符合用户需求,此时向用户提供用户修改屏幕自动旋转功能的状态的控件,解决了相关技术中切换屏幕自动旋转功能的状态操作繁琐的问题,简化了用户切换屏幕自动旋转功能的状态操作。To sum up, the picture rotation control method provided in the embodiment of the present disclosure detects the number of rotations of the electronic device, and when it is detected that the number of rotations reaches a predetermined threshold, it is considered that the current state of the automatic screen rotation function of the electronic device does not meet the user's needs. At this time, the user is provided with a control for modifying the state of the screen auto-rotation function, which solves the problem of cumbersome operation of switching the state of the screen auto-rotation function in the related art, and simplifies the user's operation of switching the state of the screen auto-rotation function.

在电子设备的屏幕自动旋转功能为解锁的情况下,为了是使用户能够在床上侧卧并在电子设备上浏览图片时,屏幕的显示方向贴合用户查看图片的需求。可通过如图2C所示的几个步骤实现屏幕自动旋转功能的锁定,图2C是根据一示例性实施例示出的一种实现屏幕自动旋转功能的锁定的方法流程图。When the automatic screen rotation function of the electronic device is unlocked, in order to enable the user to lie on the bed and browse pictures on the electronic device, the display direction of the screen meets the needs of the user to view pictures. The locking of the automatic screen rotation function can be realized through several steps as shown in FIG. 2C . FIG. 2C is a flow chart of a method for realizing the locking of the automatic screen rotation function according to an exemplary embodiment.

在步骤204a中,在图片应用程序在前台运行的过程中,获取该图片应用程序被开启前电子设备最后的屏幕显示方向。In step 204a, when the picture application program is running in the foreground, the last screen display orientation of the electronic device before the picture application program is started is obtained.

本实施例中,获取图片应用程序被开启前电子设备最后的屏幕显示方向作为贴合用户查看图片需求的参考方向。In this embodiment, the last screen display direction of the electronic device before the picture application program is started is obtained as a reference direction that meets the user's need for viewing pictures.

图2D是根据一示例性实施例示出的图片应用程序被开启前电子设备最后的屏幕显示方向的示意图。举例来讲,如图2D(1)所示,当用户通过触发桌面上图片应用程序的图标来打开该图片应用程序时,则获取到的该图片应用程序被开启前电子设备最后的屏幕显示方向为第一方向21,这里所讲的第一方向为电子设备的顶端至电子设备底端的方向。Fig. 2D is a schematic diagram showing the last screen display direction of the electronic device before the picture application program is started according to an exemplary embodiment. For example, as shown in FIG. 2D (1), when the user opens the picture application by triggering the icon of the picture application on the desktop, the acquired screen display orientation of the electronic device before the picture application is opened is is the first direction 21 , the first direction mentioned here is the direction from the top of the electronic device to the bottom of the electronic device.

再举例来讲,用户可预先设置某物理按键为触发图片应用程序前台运行的快捷按键,如图2D(2)所示,当用户利用横屏观看视频时,用户可触发上述物理按键来触发图片应用程序前台运行,则此时获取到的图片应用程序被开启前电子设备最后的屏幕显示方向为第二方向22,这里所讲的第二方向为电子设备的左侧边框至电子设备右侧边框的方向。For another example, the user can pre-set a certain physical button as a shortcut button to trigger the foreground operation of the picture application program, as shown in Figure 2D (2), when the user uses the horizontal screen to watch the video, the user can trigger the above physical button to trigger the picture If the application program is running in the foreground, the final screen display direction of the electronic device before the image application program is opened is the second direction 22, and the second direction mentioned here is from the left border of the electronic device to the right border of the electronic device direction.

触发桌面上图片应用程序的图标是一种常用的图片应用程序打开的方法,当用户通过该方法打开该图片应用程序时,获取到的屏幕显示方向为第一方向。为了使上述屏幕显示方向作为参考方向能够更贴近用户查看图片的需求,可选的,获取该图片应用程序被开启前电子设备上最后前台运行的应用程序退出时的屏幕显示方向。Triggering the icon of the picture application on the desktop is a commonly used method for opening the picture application. When the user opens the picture application through this method, the obtained screen display direction is the first direction. In order to make the above screen display direction as a reference direction closer to the user's need for viewing pictures, optionally, obtain the screen display direction when the last application running in the foreground on the electronic device exits before the picture application is opened.

比如,如图2D(2)所示,用户利用横屏观看视频后,退出用于观看视频的应用程序至电子设备的桌面后。用户通过触发桌面上的图片应用程序的图标来打开该应用程序,则电子设备获取到该图片应用程序被开启前电子设备上最后前台运行的应用程序退出时的屏幕显示方向为第二方向22,也就是说将第二方向22作为贴合用户查看图片需求的参考方向。For example, as shown in FIG. 2D(2), the user exits the application program used for watching the video to the desktop of the electronic device after using the horizontal screen to watch the video. The user opens the application by triggering the icon of the picture application on the desktop, and the electronic device obtains that the screen display direction of the last application running in the foreground on the electronic device before the picture application is opened is the second direction 22, That is to say, the second direction 22 is used as a reference direction that meets the needs of the user for viewing pictures.

在步骤204b中,获取电子设备在该图片应用程序在前台运行过程中的重力感应方向。In step 204b, the gravity sensing direction of the electronic device when the picture application program is running in the foreground is acquired.

在图片应用程序在前台运行过程中,电子设备可以通过电子设备内置的重力感应器实时获取该电子设备的重力感应方向。需要说明的一点是,电子设备获取重力感应方向是本领域普通技术人员能够实现的,因此本实施例对此不再赘述,也不对电子设备获取重力感应方向的方法作具体限定。When the picture application program is running in the foreground, the electronic device can obtain the gravity sensing direction of the electronic device in real time through the gravity sensor built in the electronic device. It should be noted that the acquisition of the gravity sensing direction by the electronic device can be realized by those skilled in the art, so this embodiment will not repeat this, nor specifically limit the method for the electronic device to obtain the gravity sensing direction.

在步骤204c中,当屏幕显示方向与重力感应方向之间的夹角首次达到第一角度阈值且电子设备的屏幕自动旋转功能为解锁时,锁定电子设备的屏幕自动旋转功能。In step 204c, when the angle between the screen display direction and the gravity sensing direction reaches the first angle threshold for the first time and the automatic screen rotation function of the electronic device is unlocked, the automatic screen rotation function of the electronic device is locked.

这里所讲的第一角度阈值通常由系统开发人员设定,本实施例对第一角度阈值的具体数据不作具体限定。The first angle threshold mentioned here is usually set by a system developer, and this embodiment does not specifically limit the specific data of the first angle threshold.

步骤204a中获取到的屏幕显示方向贴合用户查看图片需求。在电子设备的屏幕自动旋转功能为解锁的情况下,当屏幕显示方向与重力感应方向之间的夹角首次达到第一角度阈值时,为了使屏幕显示方向能够满足贴合用户需求,此时锁定电子设备的屏幕自动旋转功能,使得屏幕显示方向不发生变化。The screen display direction obtained in step 204a meets the user's requirement for viewing pictures. When the screen auto-rotation function of the electronic device is unlocked, when the angle between the screen display direction and the gravity sensing direction reaches the first angle threshold for the first time, in order to make the screen display direction meet the user's needs, lock it at this time The automatic screen rotation function of the electronic device keeps the display direction of the screen unchanged.

图2E是根据一示例性实施例示出的一种锁定屏幕显示方向的示意图。举例来讲,设定第一角度阈值为60度,当用户侧卧在床上,如图2E(1)所示,通过点击桌面上图片应用程序的图标来打开该图片应用程序时,电子设备获取到的图片应用程序被开启前电子设备最后的屏幕显示方向为第一方向21。在该图片应用程序被打开后,该应用程序在前台运行,此时电子设备的重力感应方向为第三方向23。此时,屏幕显示方向与重力感应方向之间的夹角为90度,超过第一角度阈值60度,控制屏幕自动旋转功能关闭。相应的,屏幕的显示方向仍然为第一方向21,如图2E(2)所示,符合用户侧卧时查看图片的需求。Fig. 2E is a schematic diagram showing a display direction of a locked screen according to an exemplary embodiment. For example, if the first angle threshold is set to be 60 degrees, when the user lies on the side of the bed, as shown in Figure 2E (1), when the picture application is opened by clicking the icon of the picture application on the desktop, the electronic device obtains The last screen display direction of the electronic device before the picture application is started is the first direction 21 . After the picture application program is opened, the application program runs in the foreground, and at this time, the gravity sensing direction of the electronic device is the third direction 23 . At this time, the angle between the screen display direction and the gravity sensing direction is 90 degrees, which exceeds the first angle threshold of 60 degrees, and the automatic rotation function of the control screen is turned off. Correspondingly, the display direction of the screen is still the first direction 21 , as shown in FIG. 2E ( 2 ), which meets the needs of the user to view pictures while lying on his side.

通过将图片应用程序被开启前电子设备最后的屏幕显示方向作为贴合用户浏览图片需求的参考方向,在重力感应方向与该参考方向的夹角首次达到第一角度阈值控制屏幕自动旋转功能锁定,锁定了屏幕显示方向,得屏幕的显示方向更贴合用户查看需求的问题。By using the last screen display direction of the electronic device before the picture application is opened as a reference direction that meets the needs of users to browse pictures, when the angle between the gravity sensing direction and the reference direction reaches the first angle threshold for the first time, the automatic screen rotation function is controlled to lock, The screen display direction is locked, so that the display direction of the screen is more suitable for the user's viewing needs.

在电子设备的屏幕自动旋转功能为锁定时,用户还可以通过旋转手机来解锁屏幕自动旋转功能,具体的可通过如图2F所示的几个子步骤实现,图2F是根据一示例性实施例示出的一种解锁屏幕自动旋转功能方法的流程图。When the automatic screen rotation function of the electronic device is locked, the user can also unlock the automatic screen rotation function by rotating the mobile phone. Specifically, it can be realized through several sub-steps as shown in FIG. 2F , which is shown according to an exemplary embodiment. A flow chart of a method for unlocking the automatic screen rotation function.

在步骤205a中,在电子设备的屏幕自动旋转功能为锁定时,获取电子设备的转动角加速度。In step 205a, when the automatic screen rotation function of the electronic device is locked, the rotational angular acceleration of the electronic device is obtained.

电子设备获取自身的角加速度方法是本领域普通技术人员能够实现的,因此本实施例对此不再赘述,也不对电子设备获取转动角加速度的方法作具体限定。比如,电子设备可通过电子设备中内置的陀螺仪实时获取角速度,根据实时获取的角速度确定出转动角加速度。The method for the electronic device to obtain its own angular acceleration can be implemented by those skilled in the art, so this embodiment will not describe it again, and does not specifically limit the method for the electronic device to obtain the angular acceleration of rotation. For example, the electronic device can obtain the angular velocity in real time through the gyroscope built in the electronic device, and determine the rotational angular acceleration according to the angular velocity obtained in real time.

在步骤205b中,当转动角加速度大于预定加速度阈值时,则显示第一状态修改控件。In step 205b, when the rotational angular acceleration is greater than a predetermined acceleration threshold, a first state modification control is displayed.

一般来讲,预定加速度阈值由系统开发人员设定,本实施例对预定加速度阈值的数据不作具体限定,可根据实际情况确定。当电子设备的转动角加速度大于预定加速度阈值时,则认为使用该电子设备的用户可能有变换屏幕显示方向的需要,此时显示第一状态修改控件。Generally speaking, the predetermined acceleration threshold is set by a system developer, and this embodiment does not specifically limit the data of the predetermined acceleration threshold, which can be determined according to actual conditions. When the rotational angular acceleration of the electronic device is greater than the predetermined acceleration threshold, it is considered that the user using the electronic device may need to change the display direction of the screen, and the first state modification control is displayed at this time.

在步骤205c中,当第一状态修改控件被触发时,解锁电子设备的屏幕自动旋转功能。In step 205c, when the first state modification control is triggered, the automatic screen rotation function of the electronic device is unlocked.

当电子设备的屏幕自动旋转功能为锁定时,实时获取电子设备的转动角加速度,当转动角加速度大于预定加速度阈值时,则显示第一状态修改控件,使得用户能够通过旋转电子设备触发第一状态修改控件的显示,并且可通过触发该第一状态修改控件来解锁电子设备的屏幕自动旋转功能。When the automatic screen rotation function of the electronic device is locked, obtain the rotational angular acceleration of the electronic device in real time, and when the rotational angular acceleration is greater than a predetermined acceleration threshold, display the first state modification control so that the user can trigger the first state by rotating the electronic device The display of the control is modified, and the automatic screen rotation function of the electronic device can be unlocked by triggering the first state modification control.

一些用户习惯将锁定屏幕自动旋转功能,此时电子设备的屏幕显示方向通常被锁定为第一方向。而用户在进入图片应用程序浏览图片时,有图片能够在不同的方向上进行展示需要,此时为了满足用户在查看图片时图片能够在不同的方向上进行展示的需求,解锁屏幕自动旋转功能。Some users are accustomed to locking the automatic screen rotation function, and at this time, the display orientation of the screen of the electronic device is usually locked to the first orientation. When the user enters the picture application to browse pictures, there are pictures that can be displayed in different directions. At this time, in order to meet the needs of the user to display pictures in different directions when viewing pictures, the automatic screen rotation function is unlocked.

具体的,在获取重力感应方向后,在重力感应方向与屏幕显示方向之间的夹角小于第二角度阈值且电子设备的屏幕自动旋转功能为锁定时,解锁电子设备的屏幕自动旋转功能。Specifically, after the gravity sensing direction is acquired, when the included angle between the gravity sensing direction and the screen display direction is smaller than the second angle threshold and the automatic screen rotation function of the electronic device is locked, the automatic screen rotation function of the electronic device is unlocked.

第二角度阈值通常由系统开发人员设定,本实施例对第二角度阈值的具体数据不作具体限定,可根据实际情况确定。比如,该第二角度阈值可以为30度,也可以为45度。The second angle threshold is usually set by a system developer, and this embodiment does not specifically limit the specific data of the second angle threshold, which can be determined according to actual conditions. For example, the second angle threshold may be 30 degrees or 45 degrees.

举例来讲,图2G是根据一示例性实施例示出的一种屏幕自动旋转功能解锁的示意图,设定第一角度阈值为60度,如图2G(1)所示,用户通过桌面上图片应用程序的图标来打开该图片应用程序,则电子设备获取到的图片应用程序被开启前电子设备最后的屏幕显示方向为第一方向21。如图2G(2)所示,用户打开该图片应用程序后维持姿势不变继续浏览图片,此时电子设备的重力感应方向为21且与第一方向的之间的夹角为0,解锁电子设备的屏幕自动旋转功能,则用户可通过旋转电子设备来控制照片的显示方向。For example, FIG. 2G is a schematic diagram of unlocking the automatic screen rotation function according to an exemplary embodiment. The first angle threshold is set to 60 degrees. As shown in FIG. The icon of the program is used to open the picture application program, and the last screen display direction of the electronic device before the picture application program is opened by the electronic device is the first direction 21 . As shown in Figure 2G(2), the user keeps the posture unchanged after opening the picture application and continues to browse pictures. At this time, the gravity sensing direction of the electronic device is 21 and the angle between it and the first direction is 0. With the automatic screen rotation function of the device, the user can control the display direction of the photo by rotating the electronic device.

通过检测到电子设备的重力感应方向与获取的屏幕显示方向之间的夹角小于第二角度阈值时,解锁电子设备的屏幕自动旋转功能;实现了当电子设备的屏幕显示方向通常被锁定且用户处于非侧卧姿态浏览图片的情况下,自动解除对屏幕显示方向的锁定,使得将系统的屏幕自动旋转功能关闭的用户在浏览图片时,能够通过旋转电子设备来控制照片的显示方向。By detecting that the included angle between the gravity sensing direction of the electronic device and the obtained screen display direction is less than the second angle threshold, the automatic screen rotation function of the electronic device is unlocked; when the screen display direction of the electronic device is usually locked and the user When browsing pictures in a non-sideways posture, the lock on the screen display direction is automatically unlocked, so that users who have turned off the automatic screen rotation function of the system can control the display direction of the photos by rotating the electronic device when viewing pictures.

可选的,当未获取到图片应用程序被开启前电子设备最后的屏幕显示方向时,控制电子设备的屏幕自动旋转功能处于解锁状态。Optionally, when the last screen display orientation of the electronic device before the picture application is started is not obtained, the automatic screen rotation function of the electronic device is controlled to be in an unlocked state.

每张照片在拍摄时电子设备会根据重力感应方向记录该照片的底部信息,在展示照片将该照片的底部展示在屏幕的底部。当用户手持电子设备拍摄时电子设备记录的底部与图片显示方向符合用户浏览该图片需求所对应的底部不一致时,无论屏幕显示方向如何改变都不便于用户查看,此时可以向用户提供用于控制照片旋转的控件,具体的可以通过如图2H所示的几个子步骤实现,图2H是根据一示例性实施例示出的一种向用户提供用于控制照片旋转的控件的方法流程图。When each photo is taken, the electronic device will record the bottom information of the photo according to the direction of gravity sensing, and display the bottom of the photo at the bottom of the screen when displaying the photo. When the user holds the electronic device to take pictures, the bottom of the electronic device record is inconsistent with the bottom corresponding to the user's need to browse the picture, no matter how the screen display direction changes, it is not convenient for the user to view. At this time, the user can provide the user with a control The control of photo rotation can be specifically implemented through several sub-steps as shown in FIG. 2H , which is a flow chart of a method for providing users with controls for controlling photo rotation according to an exemplary embodiment.

在步骤207a中,在电子设备的屏幕自动旋转功能为解锁时,在图片应用程序所打开的同一张图片在屏幕上持续显示的过程中,获取屏幕显示方向的变化次数。In step 207a, when the screen auto-rotation function of the electronic device is unlocked, the number of changes in the screen display direction is acquired during the continuous display of the same picture opened by the picture application program on the screen.

在步骤207b中,当变化次数达到第一次数阈值时,显示与该图片相关的图片旋转控件,根据被触发的该图片旋转控件,控制该图片进行旋转。In step 207b, when the number of changes reaches the first number threshold, a picture rotation control related to the picture is displayed, and the picture is controlled to rotate according to the triggered picture rotation control.

为了避免图片旋转控件对屏幕显示内容的遮挡,可选的,当图片旋转控件在显示屏中持续显示达到预设时长时,取消对该图片旋转控件的显示。In order to prevent the picture rotation control from blocking the content displayed on the screen, optionally, when the picture rotation control is continuously displayed on the display screen for a preset duration, the display of the picture rotation control is canceled.

第一次数阈值可以由用户设定,也可以由系统开发人员设定,本实施例对第一次数阈值的具体数值不作具体限定,可根据实际情况确定。The threshold of the first number can be set by the user or by the system developer. This embodiment does not specifically limit the specific value of the threshold of the first number, which can be determined according to the actual situation.

图2I是根据一示例性实施例示出的照片旋转示意图,以第一次数阈值为2来举例说明,如图2I(1)所示为初始展示图片A的示意图,此时图片A的展示方向不符合用户查看图片的用户需求,用户会旋转电子设备来更改屏幕的显示方向得到如图2I(2)所示的电子设备展示图片A的示意图,图2I(2)中所示的图片A的展示方向仍然不符合用户查看图片的用户需求。用户可通过再次旋转电子设备更改屏幕的显示方向以及触发与该图片相关的图片旋转控件,如图2I(3)所示,显示与图片相关的图片旋转控件包括逆时针旋转控件24以及顺时针旋转控件25。当顺时针旋转空间25被触发后,电子设备显示图片A的示意图如图2I(4)所示。Fig. 2I is a schematic diagram of photo rotation according to an exemplary embodiment, and the threshold of the first number is 2 for example. As shown in Fig. 2I (1), it is a schematic diagram of initially displaying picture A, and the display direction of picture A at this time Does not meet the user's needs for viewing pictures, the user will rotate the electronic device to change the display direction of the screen to obtain the schematic diagram of the electronic device displaying picture A as shown in Figure 2I(2), and the schematic diagram of picture A shown in Figure 2I(2) The display direction still does not meet the user's needs for users to view pictures. The user can change the display direction of the screen and trigger the picture rotation control related to the picture by rotating the electronic device again. As shown in FIG. Control 25. When the clockwise rotating space 25 is triggered, the schematic diagram of the picture A displayed by the electronic device is shown in FIG. 2I(4).

通过解锁电子设备的屏幕自动旋转功能后,在图片应用程序所打开的同一张图片在屏幕上持续显示的过程中,获取屏幕显示方向的变化次数,变化次数达到预定次数阈值时,显示与该图片相关的图片旋转控件,使得用户能够通过对图片进行旋转。After unlocking the automatic screen rotation function of the electronic device, during the continuous display of the same picture opened by the picture application program on the screen, the number of changes in the screen display direction is obtained, and when the number of changes reaches a predetermined threshold, the picture is displayed. Related picture rotation controls enable users to rotate pictures.

需要说明的一点是,本公开中对屏幕自动旋转功能的解锁与锁定,都是对电子设备系统的屏幕自动旋转功能设置的修改。It should be noted that the unlocking and locking of the screen auto-rotation function in this disclosure are all modifications to the setting of the screen auto-rotation function of the electronic device system.

可选的,当图片应用程序退出前台运行时,将电子设备的屏幕自动旋转功能的开启状态恢复至图片应用程序在前台运行前的状态。Optionally, when the picture application exits from running in the foreground, the on state of the automatic screen rotation function of the electronic device is restored to the state before the picture application runs in the foreground.

下述为本公开装置实施例,可以用于执行本公开方法实施例。对于本公开装置实施例中未披露的细节,请参照本公开方法实施例。The following are device embodiments of the present disclosure, which can be used to implement the method embodiments of the present disclosure. For details not disclosed in the disclosed device embodiments, please refer to the disclosed method embodiments.

图3是根据一示例性实施例示出的一种图片旋转控制装置的框图,该图片旋转控制装置可以包括:第一获取模块310、显示模块320和修改模块330。FIG. 3 is a block diagram showing a picture rotation control device according to an exemplary embodiment, and the picture rotation control device may include: a first acquisition module 310 , a display module 320 and a modification module 330 .

第一获取模块310,被配置为在用于显示图片的图片应用程序在前台运行过程中,获取电子设备的旋转次数。The first acquiring module 310 is configured to acquire the number of rotations of the electronic device when the picture application program for displaying pictures is running in the foreground.

显示模块320,被配置当第一获取模块310获取到的旋转次数达到预定次数阈值时,根据电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,状态为锁定或解锁。The display module 320 is configured to display the state modification control according to the current state of the screen auto-rotation function of the electronic device when the number of rotations obtained by the first obtaining module 310 reaches a predetermined threshold, and the state is locked or unlocked.

修改模块330,被配置在显示模块320显示的状态修改控件被触发时,修改屏幕自动旋转功能的状态。The modification module 330 is configured to modify the state of the automatic screen rotation function when the state modification control displayed by the display module 320 is triggered.

综上所述,本公开实施例中提供的图片旋转控制装置,通过检测电子设备的旋转次数,当检测到旋转次数达到预定次数阈值,认为电子设备当前的屏幕自动旋转功能的状态不符合用户需求,此时向用户提供用户修改屏幕自动旋转功能的状态的控件,解决了相关技术中切换屏幕自动旋转功能的状态操作繁琐的问题,简化了用户切换屏幕自动旋转功能的状态操作。To sum up, the picture rotation control device provided in the embodiment of the present disclosure detects the number of rotations of the electronic device, and when it detects that the number of rotations reaches a predetermined threshold, it considers that the current state of the automatic screen rotation function of the electronic device does not meet the user's needs. At this time, the user is provided with a control for the user to modify the state of the screen auto-rotation function, which solves the problem of cumbersome operation of switching the state of the screen auto-rotation function in the related art, and simplifies the state operation of the user switching the screen auto-rotation function.

图4是根据另一示例性实施例示出的一种图片旋转控制装置的框图,该图片旋转控制装置可以包括:第一获取模块401、显示模块402和修改模块403。FIG. 4 is a block diagram of an apparatus for controlling picture rotation according to another exemplary embodiment. The apparatus for controlling picture rotation may include: a first acquiring module 401 , a display module 402 and a modifying module 403 .

第一获取模块401,被配置为在用于显示图片的图片应用程序在前台运行过程中,获取电子设备的旋转次数。The first obtaining module 401 is configured to obtain the number of rotations of the electronic device when the picture application program for displaying pictures is running in the foreground.

这里所讲的用于显示图片的应用程序可以为图片查看器、浏览器等等。The application program used for displaying pictures mentioned here may be a picture viewer, a browser, and the like.

可选的,在图片应用程序在前台运行的过程中,实时获取电子设备的重力感应方向,根据获取到的重力感应方向确定电子设备的姿态。当检测到处于底部的边框发生变化时,记为该电子设备被旋转一次。Optionally, when the picture application program is running in the foreground, the gravity sensing direction of the electronic device is acquired in real time, and the attitude of the electronic device is determined according to the acquired gravity sensing direction. When it is detected that the frame at the bottom changes, it is recorded as that the electronic device is rotated once.

显示模块402,被配置当第一获取模块401获取到的旋转次数达到预定次数阈值时,根据电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,状态为锁定或解锁。The display module 402 is configured to display the state modification control according to the current state of the automatic screen rotation function of the electronic device when the number of rotations obtained by the first obtaining module 401 reaches a predetermined threshold, and the state is locked or unlocked.

预定次数阈值通常由系统开发人员设定,可选的,将预定次数阈值设置为2。The predetermined times threshold is usually set by a system developer, and optionally, the predetermined times threshold is set to 2.

当电子设备的旋转次数达到预定阈值时,认为当前的屏幕自动旋转功能的状态可能不符合用户的需求,此时向用户提供用于修改屏幕自动旋转功能状态的状态修改控件。When the number of rotations of the electronic device reaches a predetermined threshold, it is considered that the current state of the automatic screen rotation function may not meet the needs of the user, and at this time, a state modification control for modifying the state of the automatic screen rotation function is provided to the user.

这里所讲的屏幕自动旋转功能是电子设备根据实时获取的重力感应方向控制电子设备的屏幕显示方向自动旋转的功能。屏幕自动旋转功能的状态包括锁定和解锁,当屏幕自动旋转功能为解锁时,电子设备根据实时获取的重力感应方向控制电子设备的屏幕显示方向自动旋转;当屏幕自动旋转功能为锁定时,电子设备的屏幕显示方向被锁定。The automatic screen rotation function mentioned here is a function for the electronic device to automatically rotate the screen display direction of the electronic device according to the gravity sensing direction acquired in real time. The status of the screen auto-rotation function includes locking and unlocking. When the screen auto-rotation function is unlocked, the electronic device controls the screen display direction of the electronic device to automatically rotate according to the gravity sensing direction acquired in real time; when the screen auto-rotation function is locked, the electronic device The screen display orientation is locked.

修改模块403,被配置在显示模块402显示的状态修改控件被触发时,修改屏幕自动旋转功能的状态。The modification module 403 is configured to modify the state of the automatic screen rotation function when the state modification control displayed by the display module 402 is triggered.

可选的,显示模块402,包括:第一显示子模块402a和第二显示子模块402b。Optionally, the display module 402 includes: a first display submodule 402a and a second display submodule 402b.

第一显示子模块402a,被配置为电子设备的屏幕自动旋转功能当前的状态为锁定时,显示用于引导解锁所述屏幕自动旋转功能的第一状态修改控件。The first display sub-module 402a is configured to display a first state modification control for guiding to unlock the automatic screen rotation function when the current state of the automatic screen rotation function of the electronic device is locked.

为了第一状态修改控件对屏幕显示内容的遮挡。可选的,当第一状态修改控件在显示屏中持续显示达到预设时长时,取消对该第一状态修改控件的显示。For the first state, modify the occlusion of the content displayed on the screen by the control. Optionally, when the first state modification control is continuously displayed on the display screen for a preset duration, the display of the first state modification control is canceled.

第二显示子模块402b,被配置为当电子设备的屏幕自动旋转功能当前的状态为解锁时,显示用于引导锁定所述屏幕自动旋转功能的第二状态修改控件。The second display submodule 402b is configured to display a second state modification control for guiding to lock the automatic screen rotation function when the current state of the automatic screen rotation function of the electronic device is unlocked.

为了第二状态修改控件对屏幕显示内容的遮挡。可选的,当第二状态修改控件在显示屏中持续显示达到预设时长时,取消对该第二状态修改控件的显示。For the second state, modify the occlusion of the content displayed on the screen by the control. Optionally, when the second state modification control is continuously displayed on the display screen for a preset duration, the display of the second state modification control is canceled.

可选的,修改模块403,包括:解锁子模块403a和锁定子模块403b。Optionally, the modification module 403 includes: an unlocking submodule 403a and a locking submodule 403b.

解锁子模块403a,被配置为当显示模块显示的状态修改控件为第一状态修改控件,且第一状态修改控件被触发时,解锁电子设备的屏幕自动旋转功能。The unlocking submodule 403a is configured to unlock the automatic screen rotation function of the electronic device when the state modification control displayed by the display module is the first state modification control and the first state modification control is triggered.

锁定子模块403b,被配置为当显示模块显示的状态修改控件为第二状态修改控件,且第二状态修改控件被触发时,锁定电子设备的屏幕自动旋转功能。The locking sub-module 403b is configured to lock the automatic screen rotation function of the electronic device when the state modification control displayed by the display module is the second state modification control and the second state modification control is triggered.

可选的,该图片旋转控制装置,还包括:Optionally, the picture rotation control device also includes:

第二获取模块404,被配置为在图片应用程序在前台运行过程中,获取该图片应用程序被开启前电子设备最后的屏幕显示方向。The second acquiring module 404 is configured to acquire the last screen display direction of the electronic device before the picture application is started while the picture application is running in the foreground.

本实施例中,获取图片应用程序被开启前电子设备最后的屏幕显示方向作为贴合用户查看图片需求的参考方向。In this embodiment, the last screen display direction of the electronic device before the picture application program is started is obtained as a reference direction that meets the user's need for viewing pictures.

触发桌面上图片应用程序的图标是一种常用的图片应用程序打开的方法,当用户通过该方法打开该图片应用程序时,获取到的屏幕显示方向为第一方向。为了使上述屏幕显示方向作为参考方向能够更贴近用户查看图片的需求,可选的,获取该图片应用程序被开启前电子设备上最后前台运行的应用程序退出时的屏幕显示方向。Triggering the icon of the picture application on the desktop is a commonly used method for opening the picture application. When the user opens the picture application through this method, the obtained screen display direction is the first direction. In order to make the above screen display direction as a reference direction closer to the user's need for viewing pictures, optionally, obtain the screen display direction when the last application running in the foreground on the electronic device exits before the picture application is opened.

第三获取模块405,被配置为获取电子设备在图片应用程序在前台运行过程中的重力感应方向。The third obtaining module 405 is configured to obtain the gravity sensing direction of the electronic device when the picture application program is running in the foreground.

在图片应用程序在前台运行过程中,电子设备可以通过电子设备内置的重力传感器实时获取该电子设备的重力感应方向。需要说明的是电子设备获取重力感应方向是本领域普通技术人员能够实现的,因此本实施例对此不再赘述,也不对电子设备获取重力感应方向的方法作具体限定。When the picture application program is running in the foreground, the electronic device can obtain the gravity sensing direction of the electronic device in real time through the gravity sensor built in the electronic device. It should be noted that the acquisition of the gravity sensing direction by the electronic device can be realized by those skilled in the art, so this embodiment will not describe it again, and does not specifically limit the method for the electronic device to obtain the gravity sensing direction.

锁定模块406,被配置为当屏幕显示方向与重力感应方向之间的夹角首次达到第一角度阈值且电子设备的屏幕自动旋转功能为解锁时,锁定电子设备的屏幕自动旋转功能。The locking module 406 is configured to lock the automatic screen rotation function of the electronic device when the angle between the screen display direction and the gravity sensing direction reaches the first angle threshold for the first time and the automatic screen rotation function of the electronic device is unlocked.

这里所讲的第一角度阈值通常由系统开发人员设定,本实施例对第一角度阈值的具体数据不作具体限定。The first angle threshold mentioned here is usually set by a system developer, and this embodiment does not specifically limit the specific data of the first angle threshold.

步骤204a中获取到的屏幕显示方向贴合用户查看图片需求。在电子设备的屏幕自动旋转功能为解锁的情况下,当屏幕显示方向与重力感应方向之间的夹角首次达到第一角度阈值时,为了使屏幕显示方向能够满足贴合用户需求,此时控制电子设备的屏幕自动旋转功能关闭,使得屏幕显示方向不发生变化。The screen display direction obtained in step 204a meets the user's requirement for viewing pictures. When the screen auto-rotation function of the electronic device is unlocked, when the angle between the screen display direction and the gravity sensing direction reaches the first angle threshold for the first time, in order to make the screen display direction meet the needs of users, control The automatic screen rotation function of the electronic device is turned off, so that the display direction of the screen does not change.

可选的,该图片旋转控制装置,还包括:解锁模块407,被配置为在获取重力感应方向后,在重力感应方向与屏幕显示方向之间的夹角小于第二角度阈值且电子设备的屏幕自动旋转功能为锁定时,解锁电子设备的屏幕自动旋转功能。Optionally, the picture rotation control device further includes: an unlocking module 407 configured to, after acquiring the gravity sensing direction, the angle between the gravity sensing direction and the screen display direction is smaller than the second angle threshold and the screen of the electronic device When the automatic rotation function is locked, unlock the automatic screen rotation function of the electronic device.

第二角度阈值通常由系统开发人员设定,本实施例对第二角度阈值的具体数据不作具体限定,可根据实际情况确定。The second angle threshold is usually set by a system developer, and this embodiment does not specifically limit the specific data of the second angle threshold, which can be determined according to actual conditions.

可选的,该图片旋转控制装置,还包括:控制模块408,被配置为当未获取到图片应用程序被开启前电子设备最后的屏幕显示方向时,控制电子设备的屏幕自动旋转功能处于解锁状态。Optionally, the picture rotation control device further includes: a control module 408 configured to control the automatic screen rotation function of the electronic device to be in an unlocked state when the last screen display direction of the electronic device before the picture application program is started is not acquired .

可选的,该图片旋转控制装置,还包括:恢复模块409,被配置为当图片应用程序退出前台运行时,将电子设备的屏幕自动旋转功能的开启状态恢复至图片应用程序在前台运行前的状态。Optionally, the picture rotation control device further includes: a restoration module 409, configured to restore the automatic screen rotation function of the electronic device to the state before the picture application program runs in the foreground when the picture application program exits the foreground. state.

综上所述,本公开实施例中提供的图片旋转控制装置,通过检测电子设备的旋转次数,当检测到旋转次数达到预定次数阈值,认为电子设备当前的屏幕自动旋转功能的状态不符合用户需求,此时向用户提供用户修改屏幕自动旋转功能的状态的控件,解决了相关技术中切换屏幕自动旋转功能的状态操作繁琐的问题,简化了用户切换屏幕自动旋转功能的状态操作。To sum up, the picture rotation control device provided in the embodiment of the present disclosure detects the number of rotations of the electronic device, and when it detects that the number of rotations reaches a predetermined threshold, it considers that the current state of the automatic screen rotation function of the electronic device does not meet the user's needs. At this time, the user is provided with a control for the user to modify the state of the screen auto-rotation function, which solves the problem of cumbersome operation of switching the state of the screen auto-rotation function in the related art, and simplifies the state operation of the user switching the screen auto-rotation function.

需要说明的一点是,上述实施例提供的装置在图片旋转控制功能时,仅以上述各个功能模块的划分进行举例说明,实际应用中,可以根据实际需要而将上述功能分配由不同的功能模块完成,即将设备的内容结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。It should be noted that the device provided by the above embodiment only uses the division of the above functional modules as an example for the picture rotation control function. In practical applications, the above function allocation can be completed by different functional modules according to actual needs. , which divides the content structure of the device into different functional modules to complete all or part of the functions described above.

关于上述实施例中的装置,其中各个模块执行操作的具体方式已经在有关该方法的实施例中进行了详细描述,此处将不做详细阐述说明。Regarding the apparatus in the foregoing embodiments, the specific manner in which each module executes operations has been described in detail in the embodiments related to the method, and will not be described in detail here.

本公开一示例性实施例还提供了一种图片旋转控制装置,能够实现本公开提供的图片旋转控制方法。该装置包括:处理器,以及用于存储处理器的可执行指令的存储器。其中,处理器被配置为:An exemplary embodiment of the present disclosure also provides a picture rotation control device capable of implementing the picture rotation control method provided in the present disclosure. The device includes: a processor, and a memory for storing executable instructions of the processor. where the processor is configured as:

在用于显示图片的图片应用程序在前台运行过程中,获取电子设备的旋转次数。When the picture application for displaying pictures is running in the foreground, the number of rotations of the electronic device is acquired.

当旋转次数达到预定次数阈值时,根据电子设备的屏幕自动旋转功能当前的状态,显示状态修改控件,上述状态为锁定或解锁。When the number of rotations reaches a predetermined threshold, a state modification control is displayed according to the current state of the automatic screen rotation function of the electronic device, and the above state is locked or unlocked.

在状态修改控件被触发时,修改屏幕自动旋转功能的状态。Modify the state of the screen auto-rotate function when the state modification control is triggered.

图5是根据一示例性实施例示出的一种用于图片旋转控制的装置500的框图。例如,装置500可以是移动电话,计算机,数字广播终端,消息收发设备,游戏控制台,平板设备,医疗设备,健身设备,个人数字助理等。Fig. 5 is a block diagram of an apparatus 500 for picture rotation control according to an exemplary embodiment. For example, the apparatus 500 may be a mobile phone, a computer, a digital broadcast terminal, a messaging device, a game console, a tablet device, a medical device, a fitness device, a personal digital assistant, and the like.

参照图5,装置500可以包括以下一个或多个组件:处理组件502,存储器504,电源组件506,多媒体组件508,音频组件510,输入/输出(I/O)的接口512,传感器组件514,以及通信组件516。5, device 500 may include one or more of the following components: processing component 502, memory 504, power supply component 506, multimedia component 508, audio component 510, input/output (I/O) interface 512, sensor component 514, and communication component 516 .

处理组件502通常控制装置500的整体操作,诸如与显示,电话呼叫,数据通信,相机操作和记录操作相关联的操作。处理组件502可以包括一个或多个处理器520来执行指令,以完成上述的方法的全部或部分步骤。此外,处理组件502可以包括一个或多个模块,便于处理组件502和其他组件之间的交互。例如,处理组件502可以包括多媒体模块,以方便多媒体组件508和处理组件502之间的交互。The processing component 502 generally controls the overall operations of the device 500, such as those associated with display, telephone calls, data communications, camera operations, and recording operations. The processing component 502 may include one or more processors 520 to execute instructions to complete all or part of the steps of the above method. Additionally, processing component 502 may include one or more modules that facilitate interaction between processing component 502 and other components. For example, processing component 502 may include a multimedia module to facilitate interaction between multimedia component 508 and processing component 502 .

存储器504被配置为存储各种类型的数据以支持在装置500的操作。这些数据的示例包括用于在装置500上操作的任何应用程序或方法的指令,联系人数据,电话簿数据,消息,图片,视频等。存储器504可以由任何类型的易失性或非易失性存储设备或者它们的组合实现,如静态随机存取存储器(SRAM),电可擦除可编程只读存储器(EEPROM),可擦除可编程只读存储器(EPROM),可编程只读存储器(PROM),只读存储器(ROM),磁存储器,快闪存储器,磁盘或光盘。The memory 504 is configured to store various types of data to support operations at the device 500 . Examples of such data include instructions for any application or method operating on device 500, contact data, phonebook data, messages, pictures, videos, and the like. The memory 504 can be implemented by any type of volatile or non-volatile storage device or their combination, such as static random access memory (SRAM), electrically erasable programmable read-only memory (EEPROM), erasable Programmable Read Only Memory (EPROM), Programmable Read Only Memory (PROM), Read Only Memory (ROM), Magnetic Memory, Flash Memory, Magnetic or Optical Disk.

电源组件506为装置500的各种组件提供电力。电源组件506可以包括电源管理系统,一个或多个电源,及其他与为装置500生成、管理和分配电力相关联的组件。The power supply component 506 provides power to various components of the device 500 . Power components 506 may include a power management system, one or more power supplies, and other components associated with generating, managing, and distributing power for device 500 .

多媒体组件508包括在所述装置500和用户之间的提供一个输出接口的屏幕。在一些实施例中,屏幕可以包括液晶显示器(LCD)和触摸面板(TP)。如果屏幕包括触摸面板,屏幕可以被实现为触摸屏,以接收来自用户的输入信号。触摸面板包括一个或多个触摸传感器以感测触摸、滑动和触摸面板上的手势。所述触摸传感器可以不仅感测触摸或滑动动作的边界,而且还检测与所述触摸或滑动操作相关的持续时间和压力。在一些实施例中,多媒体组件508包括一个前置摄像头和/或后置摄像头。当装置500处于操作模式,如拍摄模式或视频模式时,前置摄像头和/或后置摄像头可以接收外部的多媒体数据。每个前置摄像头和后置摄像头可以是一个固定的光学透镜系统或具有焦距和光学变焦能力。The multimedia component 508 includes a screen that provides an output interface between the device 500 and the user. In some embodiments, the screen may include a liquid crystal display (LCD) and a touch panel (TP). If the screen includes a touch panel, the screen may be implemented as a touch screen to receive input signals from a user. The touch panel includes one or more touch sensors to sense touches, swipes, and gestures on the touch panel. The touch sensor may not only sense a boundary of a touch or swipe action, but also detect duration and pressure associated with the touch or swipe action. In some embodiments, the multimedia component 508 includes a front camera and/or a rear camera. When the device 500 is in an operation mode, such as a shooting mode or a video mode, the front camera and/or the rear camera can receive external multimedia data. Each front camera and rear camera can be a fixed optical lens system or have focal length and optical zoom capability.

音频组件510被配置为输出和/或输入音频信号。例如,音频组件510包括一个麦克风(MIC),当装置500处于操作模式,如呼叫模式、记录模式和语音识别模式时,麦克风被配置为接收外部音频信号。所接收的音频信号可以被进一步存储在存储器504或经由通信组件516发送。在一些实施例中,音频组件510还包括一个扬声器,用于输出音频信号。The audio component 510 is configured to output and/or input audio signals. For example, the audio component 510 includes a microphone (MIC), which is configured to receive external audio signals when the device 500 is in operation modes, such as call mode, recording mode and voice recognition mode. Received audio signals may be further stored in memory 504 or sent via communication component 516 . In some embodiments, the audio component 510 also includes a speaker for outputting audio signals.

I/O接口512为处理组件502和外围接口模块之间提供接口,上述外围接口模块可以是键盘,点击轮,控件等。这些控件可包括但不限于:主页控件、音量控件、启动控件和锁定控件。The I/O interface 512 provides an interface between the processing component 502 and a peripheral interface module, which may be a keyboard, a click wheel, a control, and the like. These controls may include, but are not limited to: home page controls, volume controls, startup controls, and lock controls.

传感器组件514包括一个或多个传感器,用于为装置500提供各个方面的状态评估。例如,传感器组件514可以检测到装置500的打开/关闭状态,组件的相对定位,例如所述组件为装置500的显示器和小键盘,传感器组件514还可以检测装置500或装置500一个组件的位置改变,用户与装置500接触的存在或不存在,装置500方位或加速/减速和装置500的温度变化。传感器组件514可以包括接近传感器,被配置用来在没有任何的物理接触时检测附近物体的存在。传感器组件514还可以包括光传感器,如CMOS或CCD图像传感器,用于在成像应用中使用。在一些实施例中,该传感器组件514还可以包括加速度传感器,陀螺仪传感器,磁传感器,压力传感器或温度传感器。Sensor assembly 514 includes one or more sensors for providing status assessments of various aspects of device 500 . For example, the sensor component 514 can detect the open/closed state of the device 500, the relative positioning of components, such as the display and keypad of the device 500, and the sensor component 514 can also detect a change in the position of the device 500 or a component of the device 500 , the presence or absence of user contact with the device 500 , the device 500 orientation or acceleration/deceleration and the temperature change of the device 500 . Sensor assembly 514 may include a proximity sensor configured to detect the presence of nearby objects in the absence of any physical contact. Sensor assembly 514 may also include an optical sensor, such as a CMOS or CCD image sensor, for use in imaging applications. In some embodiments, the sensor component 514 may also include an acceleration sensor, a gyroscope sensor, a magnetic sensor, a pressure sensor or a temperature sensor.

通信组件516被配置为便于装置500和其他设备之间有线或无线方式的通信。装置500可以接入基于通信标准的无线网络,如WiFi,2G或3G,或它们的组合。在一个示例性实施例中,通信组件516经由广播信道接收来自外部广播管理系统的广播信号或广播相关信息。在一个示例性实施例中,所述通信组件516还包括近场通信(NFC)模块,以促进短程通信。例如,在NFC模块可基于射频识别(RFID)技术,红外数据协会(IrDA)技术,超宽带(UWB)技术,蓝牙(BT)技术和其他技术来实现。The communication component 516 is configured to facilitate wired or wireless communication between the apparatus 500 and other devices. The device 500 can access wireless networks based on communication standards, such as WiFi, 2G or 3G, or a combination thereof. In an exemplary embodiment, the communication component 516 receives broadcast signals or broadcast related information from an external broadcast management system via a broadcast channel. In an exemplary embodiment, the communication component 516 also includes a near field communication (NFC) module to facilitate short-range communication. For example, the NFC module may be implemented based on Radio Frequency Identification (RFID) technology, Infrared Data Association (IrDA) technology, Ultra Wide Band (UWB) technology, Bluetooth (BT) technology and other technologies.

在示例性实施例中,装置500可以被一个或多个应用专用集成电路(ASIC)、数字信号处理器(DSP)、数字信号处理设备(DSPD)、可编程逻辑器件(PLD)、现场可编程门阵列(FPGA)、控制器、微控制器、微处理器或其他电子元件实现,用于执行上述方法。In an exemplary embodiment, apparatus 500 may be programmed by one or more application specific integrated circuits (ASICs), digital signal processors (DSPs), digital signal processing devices (DSPDs), programmable logic devices (PLDs), field programmable A gate array (FPGA), controller, microcontroller, microprocessor or other electronic component implementation for performing the methods described above.

在示例性实施例中,还提供了一种包括指令的非临时性计算机可读存储介质,例如包括指令的存储器504,上述指令可由装置500的处理器520执行以完成上述方法。例如,所述非临时性计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。In an exemplary embodiment, there is also provided a non-transitory computer-readable storage medium including instructions, such as the memory 504 including instructions, which can be executed by the processor 520 of the device 500 to implement the above method. For example, the non-transitory computer readable storage medium may be ROM, random access memory (RAM), CD-ROM, magnetic tape, floppy disk, optical data storage device, and the like.

一种非临时性计算机可读存储介质,当所述存储介质中的指令由装置500的处理器执行时,使得装置500能够执行图1、图2A、图2C、图2F和图2H中所示的步骤。A non-transitory computer-readable storage medium that, when the instructions in the storage medium are executed by the processor of the device 500, enables the device 500 to perform the operations shown in FIGS. A step of.

本领域技术人员在考虑说明书及实践这里公开的发明后,将容易想到本公开的其它实施方案。本申请旨在涵盖本公开的任何变型、用途或者适应性变化,这些变型、用途或者适应性变化遵循本公开的一般性原理并包括本公开未公开的本技术领域中的公知常识或惯用技术手段。说明书和实施例仅被视为示例性的,本公开的真正范围和精神由下面的权利要求指出。Other embodiments of the present disclosure will be readily apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any modification, use or adaptation of the present disclosure, and these modifications, uses or adaptations follow the general principles of the present disclosure and include common knowledge or conventional technical means in the technical field not disclosed in the present disclosure . The specification and examples are to be considered exemplary only, with a true scope and spirit of the disclosure being indicated by the following claims.

应当理解的是,本公开并不局限于上面已经描述并在附图中示出的精确结构,并且可以在不脱离其范围进行各种修改和改变。本公开的范围仅由所附的权利要求来限制。It should be understood that the present disclosure is not limited to the precise constructions which have been described above and shown in the drawings, and various modifications and changes may be made without departing from the scope thereof. The scope of the present disclosure is limited only by the appended claims.

Claims (14)

1. a kind of picture rotation control method, which is characterized in that be applied in electronic equipment, which comprises
In the picture application program for showing picture during front stage operation, the number of revolutions of the electronic equipment is obtained, The number of revolutions is obtained by the frame variation determination in bottom;
When the number of revolutions reaches pre-determined number threshold value, current according to the screen automatic rotation function of the electronic equipment State shows status modifier control, and the state is to lock or unlock, and the status modifier control revolves automatically for modifying screen Rotating function state;
When the status modifier control is triggered, the state of the screen automatic rotation function is modified;
In the picture application program during front stage operation, obtains the electronics before the picture application program is turned on and set Standby last screen display direction;
Obtain gravity sensing direction of the electronic equipment during picture application program is in front stage operation;
When the angle between the screen display direction and the gravity sensing direction reaches first angle threshold value and described for the first time When the screen automatic rotation function of electronic equipment is unlock, the screen automatic rotation function of the electronic equipment is locked.
2. the method according to claim 1, wherein the automatic rotational work of the screen according to the electronic equipment The current state of energy, shows status modifier control, comprising:
When the current state of the screen automatic rotation function of the electronic equipment is locking, display unlocks the screen for guiding The first state of curtain automatic rotation function modifies control;
When the current state of the screen automatic rotation function of the electronic equipment is unlock, display described in guiding locking for shielding Second status modifier control of curtain automatic rotation function.
3. according to the method described in claim 2, it is characterized in that, described when the status modifier control is triggered, modification The state of the screen automatic rotation function, comprising:
When the status modifier control is first state modification control, and first state modification control is triggered, Unlock the screen automatic rotation function of the electronic equipment;
When the status modifier control is the second status modifier control, and the second status modifier control is triggered, Lock the screen automatic rotation function of the electronic equipment.
4. the method according to claim 1, wherein the method also includes:
After obtaining the gravity sensing direction, the angle between the gravity sensing direction and the screen display direction is small When the screen automatic rotation function of second angle threshold value and the electronic equipment is locking, the screen of the electronic equipment is unlocked Automatic rotation function.
5. the method according to claim 1, wherein the method also includes:
Before the picture application program has not been obtained and is turned on when the last screen display direction of electronic equipment, the electricity is controlled The screen automatic rotation function of sub- equipment is in the unlocked state.
6. according to claim 1 to any method in 5, which is characterized in that the method also includes:
When the picture application program exits front stage operation, by the opening state of the screen automatic rotation function of the electronic equipment State restores the state to the picture application program before front stage operation.
7. a kind of picture rotation control device, which is characterized in that described device includes:
First obtains module, is configured as in the picture application program for showing picture during front stage operation, obtains electricity The number of revolutions of sub- equipment, the number of revolutions are obtained by the frame variation determination in bottom;
Display module is configured when the number of revolutions that the first acquisition module is got reaches pre-determined number threshold value, according to The current state of the screen automatic rotation function of the electronic equipment, shows status modifier control, and the state is locking or solution Lock, the status modifier control is for modifying screen automatic rotation function state;
It is automatic to modify the screen when being configured in the status modifier control that the display module is shown and being triggered for modified module The state of rotation function;
Second obtains module, is configured as in the picture application program during front stage operation, obtains the picture application The last screen display direction of the electronic equipment before program is turned on;
Third obtains module, is configured as obtaining the electronic equipment during picture application program is in front stage operation Gravity sensing direction;
Locking module is configured as reaching for the first time when angle between the screen display direction and the gravity sensing direction When the screen automatic rotation function of one angle threshold and the electronic equipment is unlock, the screen for locking the electronic equipment is automatic Rotation function.
8. device according to claim 7, which is characterized in that the display module includes:
First display sub-module, when being configured as the current state of screen automatic rotation function of the electronic equipment as locking, Display unlocks the first state modification control of the screen automatic rotation function for guiding;
Second display sub-module is configured as when the current state of the screen automatic rotation function of the electronic equipment being unlock When, second status modifier control of the display for screen automatic rotation function described in guiding locking.
9. device according to claim 8, which is characterized in that the modified module includes:
Submodule is unlocked, the status modifier control for being configured as showing when the display module is first state modification control Part, and first state modification control unlocks the screen automatic rotation function of the electronic equipment when being triggered;
Submodule is locked, the status modifier control for being configured as showing when the display module is the second status modifier control Part, and when the second status modifier control is triggered, lock the screen automatic rotation function of the electronic equipment.
10. device according to claim 7, which is characterized in that described device further include:
Unlocked state is configured as after obtaining the gravity sensing direction, aobvious in the gravity sensing direction and the screen Showing that the angle between direction is less than second angle threshold value and the screen automatic rotation function of the electronic equipment is unlock when locking The screen automatic rotation function of the electronic equipment.
11. device according to claim 7, which is characterized in that described device further include:
Control module is configured as the screen that electronic equipment is last before the picture application program has not been obtained and is turned on and shows When direction, the screen automatic rotation function for controlling the electronic equipment is in the unlocked state.
12. according to the device any in claim 7 to 11, which is characterized in that described device further include:
Recovery module is configured as when the picture application program exits front stage operation, certainly by the screen of the electronic equipment The open state of dynamic rotation function restores the state to the picture application program before front stage operation.
13. a kind of picture rotation control device characterized by comprising
Processor;
For storing the memory of the executable instruction of the processor;
Wherein, the processor is configured to:
In the picture application program for showing picture during front stage operation, the number of revolutions of electronic equipment is obtained, it is described Number of revolutions is obtained by the frame variation determination in bottom;
When the number of revolutions reaches pre-determined number threshold value, current according to the screen automatic rotation function of the electronic equipment State shows status modifier control, and the state is to lock or unlock, and the status modifier control revolves automatically for modifying screen Rotating function state;
When the status modifier control is triggered, the state of the screen automatic rotation function is modified;
In the picture application program during front stage operation, obtains the electronics before the picture application program is turned on and set Standby last screen display direction;
Obtain gravity sensing direction of the electronic equipment during picture application program is in front stage operation;
When the angle between the screen display direction and the gravity sensing direction reaches first angle threshold value and described for the first time When the screen automatic rotation function of electronic equipment is unlock, the screen automatic rotation function of the electronic equipment is locked.
14. a kind of computer readable storage medium, which is characterized in that the computer-readable recording medium storage at least one refers to It enables, claim 1-6 any picture rotation control method is realized when described instruction is executed by processor.
CN201610371869.6A 2016-05-30 2016-05-30 Picture rotation control method and device Active CN106020649B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201610371869.6A CN106020649B (en) 2016-05-30 2016-05-30 Picture rotation control method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201610371869.6A CN106020649B (en) 2016-05-30 2016-05-30 Picture rotation control method and device

Publications (2)

Publication Number Publication Date
CN106020649A CN106020649A (en) 2016-10-12
CN106020649B true CN106020649B (en) 2019-09-13

Family

ID=57091482

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201610371869.6A Active CN106020649B (en) 2016-05-30 2016-05-30 Picture rotation control method and device

Country Status (1)

Country Link
CN (1) CN106020649B (en)

Families Citing this family (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106547456A (en) * 2016-10-27 2017-03-29 北京小米移动软件有限公司 Terminal unit screen rotation method and device
CN107918517B (en) * 2017-11-13 2020-02-18 Oppo广东移动通信有限公司 Response method, device, mobile terminal and storage medium for screen rotation
CN107765973A (en) * 2017-11-16 2018-03-06 珠海市魅族科技有限公司 Control method and device, computer installation and the storage medium in screen display direction
CN108196699B (en) * 2017-12-19 2021-02-02 维沃移动通信有限公司 Page switching method and equipment
CN108958860B (en) * 2018-06-06 2022-03-08 Oppo(重庆)智能科技有限公司 Screen display state control method and related product
CN113970995B (en) * 2021-10-25 2024-12-27 超越科技股份有限公司 A screen flipping method and electronic device based on Linux system
CN114398134A (en) * 2022-01-14 2022-04-26 北京字跳网络技术有限公司 A locking method, device, electronic device and medium

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102799370A (en) * 2012-06-29 2012-11-28 珠海金山办公软件有限公司 Method and system for controlling rotation of screen of touch terminal
CN103176710A (en) * 2011-09-23 2013-06-26 三星电子株式会社 Apparatus and method for locking automatic screen rotation in portable terminal
CN103793166A (en) * 2012-11-05 2014-05-14 阿里巴巴集团控股有限公司 Method for rotational displaying of content and terminal
CN103955324A (en) * 2014-03-28 2014-07-30 广州华多网络科技有限公司 Method and method for displaying interfaces

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9292165B2 (en) * 2013-10-09 2016-03-22 Conduit Ltd Multiple-mode interface for spatial input devices

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103176710A (en) * 2011-09-23 2013-06-26 三星电子株式会社 Apparatus and method for locking automatic screen rotation in portable terminal
CN102799370A (en) * 2012-06-29 2012-11-28 珠海金山办公软件有限公司 Method and system for controlling rotation of screen of touch terminal
CN103793166A (en) * 2012-11-05 2014-05-14 阿里巴巴集团控股有限公司 Method for rotational displaying of content and terminal
CN103955324A (en) * 2014-03-28 2014-07-30 广州华多网络科技有限公司 Method and method for displaying interfaces

Also Published As

Publication number Publication date
CN106020649A (en) 2016-10-12

Similar Documents

Publication Publication Date Title
CN106020649B (en) Picture rotation control method and device
CN105159640B (en) Display interface rotating method and device and mobile terminal
CN109557999B (en) Bright screen control method and device and storage medium
CN107800945A (en) Method and device that panorama is taken pictures, electronic equipment
CN110662095A (en) Screen projection processing method, device, terminal and storage medium
CN107426502B (en) Shooting method and device, electronic equipment and storage medium
CN107357505A (en) The method, apparatus and computer-readable recording medium of screenshot capture
CN107102801A (en) Terminal screen spinning solution and device
US11372516B2 (en) Method, device, and storage medium for controlling display of floating window
WO2016023339A1 (en) Photographing delay method and device
KR101788496B1 (en) Method and apparatus for controlling video image and terminal
CN111385456A (en) Photographing preview method and device and storage medium
CN106547462B (en) Photographing control method and device and mobile terminal
CN114071001B (en) Control method, control device, electronic equipment and storage medium
CN107566878B (en) Method and device for displaying pictures in live broadcast
CN107197107B (en) Method and device for processing starting instruction
CN107132983B (en) Split screen window operation method and device
CN110865720B (en) Human posture reminder method and device
CN106547456A (en) Terminal unit screen rotation method and device
CN107423378A (en) Image display method and device
CN107145797A (en) Application Icon Display Control Method, Device, and Terminal Equipment
CN108111751A (en) Shooting angle method of adjustment and device
CN114721578A (en) Input control display method and device, electronic equipment and storage medium
US11783525B2 (en) Method, device and storage medium form playing animation of a captured image
CN106528197B (en) Shooting method and device

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant