A tangible, non-transitory computer readable medium having stored therein instructions, that when executed by an electronic device with a processor, cause the electronic device to refresh a display, refreshable at one of a plurality of refresh rates, in response to the electronic device's shaking degree, comprising
- setting a plurality of set shaking rates associating with the refresh rates;
- obtaining a plurality of shaking degrees from the electronic device;
- calculating an average shaking degree based on the shaking degrees;
- dividing the average shaking degree by a maximum shaking degree of the electronic device to obtain a determined shaking rate;
- comparing the determined shaking rate against the set shaking rates to select an appropriate refresh rate out of the set shaking rates;
- and
- refreshing the display at the appropriate refresh rate.