Прочитал данную темку. Изменил файлик FMX.Helpers.Android.pas, прикрепил к проекту и ничего не изменилось. Окно как было старым, так и осталось (Messagedlg). Может быть что-то помимо этого нужно сделать?
function GetNativeTheme: Integer;
var
LStyleDescriptor: TStyleDescription;
begin
Result := 0;
if not IsGingerbreadDevice and (Screen <> nil) and (Screen.ActiveForm <> nil) and
(Screen.ActiveForm.StyleBook <> nil) then
begin
LStyleDescriptor := TStyleManager.FindStyleDescriptor(Screen.ActiveForm.StyleBook.Style);
// the original code -->GetThemeFromDescriptor(LStyleDescriptor);
// the next line has the modified code to set the result
Result := GetThemeFromDescriptor(LStyleDescriptor);
end;
end;
function GetNativeTheme(const AControl: TControl): Integer;
var
LStyleDescriptor: TStyleDescription;
begin
Result := 0;
if not IsGingerbreadDevice then
begin
LStyleDescriptor := TStyleManager.GetStyleDescriptionForControl(AControl);
// GetThemeFromDescriptor(LStyleDescriptor);
Result := GetThemeFromDescriptor(LStyleDescriptor); // <--here the result assignment was missing
end;
end;
Вопрос
Satellite
Прочитал данную темку. Изменил файлик FMX.Helpers.Android.pas, прикрепил к проекту и ничего не изменилось. Окно как было старым, так и осталось (Messagedlg). Может быть что-то помимо этого нужно сделать?
function GetNativeTheme: Integer; var LStyleDescriptor: TStyleDescription; begin Result := 0; if not IsGingerbreadDevice and (Screen <> nil) and (Screen.ActiveForm <> nil) and (Screen.ActiveForm.StyleBook <> nil) then begin LStyleDescriptor := TStyleManager.FindStyleDescriptor(Screen.ActiveForm.StyleBook.Style); // the original code -->GetThemeFromDescriptor(LStyleDescriptor); // the next line has the modified code to set the result Result := GetThemeFromDescriptor(LStyleDescriptor); end; end;function GetNativeTheme(const AControl: TControl): Integer; var LStyleDescriptor: TStyleDescription; begin Result := 0; if not IsGingerbreadDevice then begin LStyleDescriptor := TStyleManager.GetStyleDescriptionForControl(AControl); // GetThemeFromDescriptor(LStyleDescriptor); Result := GetThemeFromDescriptor(LStyleDescriptor); // <--here the result assignment was missing end; end;Окно должно стать таким:

Изменено пользователем Satellite12 ответов на этот вопрос
Рекомендуемые сообщения
Присоединяйтесь к обсуждению
Вы можете написать сейчас и зарегистрироваться позже. Если у вас есть аккаунт, авторизуйтесь, чтобы опубликовать от имени своего аккаунта.