Review: Needs Information

See inline comments

Diff comments:

> 
> === modified file 'openlp/core/common/i18n.py'
> --- openlp/core/common/i18n.py        2019-06-28 18:09:25 +0000
> +++ openlp/core/common/i18n.py        2019-07-18 19:27:49 +0000
> @@ -338,8 +338,8 @@
>          Override the default object creation method to return a single 
> instance.
>          """
>          if not cls.__instance__:
> -            cls.__instance__ = object.__new__(cls)
> -            cls.load(cls)
> +            cls.__instance__ = super().__new__(cls)
> +            cls.__instance__.load()

This was changed  to improve performance as it was doing a full initialisation 
each time it was run.
put a print statement at the top of load and check how many times it comes out.

Also in icons as well

>          return cls.__instance__
>  
>      def load(self):
> 
> === modified file 'openlp/core/ui/icons.py'
> --- openlp/core/ui/icons.py   2019-04-13 13:00:22 +0000
> +++ openlp/core/ui/icons.py   2019-07-18 19:27:49 +0000
> @@ -45,8 +45,8 @@
>          Override the default object creation method to return a single 
> instance.
>          """
>          if not cls.__instance__:
> -            cls.__instance__ = object.__new__(cls)
> -            cls.load(cls)
> +            cls.__instance__ = super().__new__(cls)
> +            cls.__instance__.load()
>          return cls.__instance__

See above

>  
>      def load(self):
> 
> === modified file 'openlp/core/widgets/views.py'
> --- openlp/core/widgets/views.py      2019-05-23 19:33:46 +0000
> +++ openlp/core/widgets/views.py      2019-07-18 19:27:49 +0000
> @@ -219,7 +219,7 @@
>                  slide_height = width // self.screen_ratio
>                  max_img_row_height = Settings().value('advanced/slide max 
> height')
>                  if isinstance(max_img_row_height, int):
> -                    if max_img_row_height > 0 and slide_height > 
> max_img_row_height:
> +                    if 0 < max_img_row_height < slide_height:

Please check this as we have had this type of structure before and it did not 
work!

>                          slide_height = max_img_row_height
>                      elif max_img_row_height < 0:
>                          # If auto setting, show that number of slides, or if 
> the resulting slides too small, 100px.


-- 
https://code.launchpad.net/~phill-ridout/openlp/fixes-III/+merge/370337
Your team OpenLP Core is subscribed to branch lp:openlp.

_______________________________________________
Mailing list: https://launchpad.net/~openlp-core
Post to     : [email protected]
Unsubscribe : https://launchpad.net/~openlp-core
More help   : https://help.launchpad.net/ListHelp

Reply via email to