Why does debugger say that the documented OpenLaszlo lz.FocusService.getFocus() method doesn't exist

StackOverflow https://stackoverflow.com/questions/12753220

  •  05-07-2021
  •  | 
  •  

سؤال

The lz.Focus reference manual documentation for the latest official release (4.9.0) of the OpenLaszlo programming platform (http://www.openlaszlo.org/lps4.9/docs/reference/) gives many examples of calling methods on the lz.FocusService object, however, many of the examples do not work:

eg:

lz.FocusService.getFocus();

Calling this command responds in the following debugger window error:

TypeError: Error #1006: getFocus is not a function.

Why do I get this error trying to use it?

هل كانت مفيدة؟

المحلول

The OpenLaszlo 4.9.0 reference manual documentation is confusing. Calling the lz.Focus object (instead of lz.FocusService) with the same method names seems to work.

eg:

lz.Focus.getFocus();

This does not give an error.

مرخصة بموجب: CC-BY-SA مع الإسناد
لا تنتمي إلى StackOverflow
scroll top